projects
/
linux-2.6-block.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
74dd7c9
)
gfs2_meta: ->mount() can get NULL dev_name
author
Al Viro
<viro@zeniv.linux.org.uk>
Sat, 13 Oct 2018 04:19:13 +0000
(
00:19
-0400)
committer
Al Viro
<viro@zeniv.linux.org.uk>
Sat, 13 Oct 2018 04:19:13 +0000
(
00:19
-0400)
get in sync with mount_bdev() handling of the same
Reported-by: syzbot+c54f8e94e6bba03b04e9@syzkaller.appspotmail.com
Cc: stable@vger.kernel.org
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
fs/gfs2/ops_fstype.c
patch
|
blob
|
blame
|
history
diff --git
a/fs/gfs2/ops_fstype.c
b/fs/gfs2/ops_fstype.c
index c2469833b4fba92d8d1be90b3637379b904920a7..6b84ef6ccff3f28937e8fe65a75dac2696be5a00 100644
(file)
--- a/
fs/gfs2/ops_fstype.c
+++ b/
fs/gfs2/ops_fstype.c
@@
-1333,6
+1333,9
@@
static struct dentry *gfs2_mount_meta(struct file_system_type *fs_type,
struct path path;
int error;
+ if (!dev_name || !*dev_name)
+ return ERR_PTR(-EINVAL);
+
error = kern_path(dev_name, LOOKUP_FOLLOW, &path);
if (error) {
pr_warn("path_lookup on %s returned error %d\n",