projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5c8fe58
)
do_tmpfile(): don't mess with finish_open()
author
Al Viro
<viro@zeniv.linux.org.uk>
Wed, 11 Mar 2020 21:22:19 +0000
(17:22 -0400)
committer
Al Viro
<viro@zeniv.linux.org.uk>
Mon, 4 Jan 2021 02:06:02 +0000
(21:06 -0500)
use vfs_open() instead
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
fs/namei.c
patch
|
blob
|
history
diff --git
a/fs/namei.c
b/fs/namei.c
index 78443a85480a5aea3b04b3064bb3ef594c83777b..a3b3ca62ef5c0cb4db79d7af71215bb2bb5a0758 100644
(file)
--- a/
fs/namei.c
+++ b/
fs/namei.c
@@
-3325,10
+3325,8
@@
static int do_tmpfile(struct nameidata *nd, unsigned flags,
audit_inode(nd->name, child, 0);
/* Don't check for other permissions, the inode was just created */
error = may_open(&path, 0, op->open_flag);
- if (error)
- goto out2;
- file->f_path.mnt = path.mnt;
- error = finish_open(file, child, NULL);
+ if (!error)
+ error = vfs_open(&path, file);
out2:
mnt_drop_write(path.mnt);
out: