diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2016-11-21 02:27:12 +0100 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2016-12-06 01:03:49 +0100 |
commit | f0bb5aaf2c51267c49ed5e2c6103df22acfe30f5 (patch) | |
tree | ed42ba59576c11ad22daeae5291cfe3f5b71a9a1 /fs/namei.c | |
parent | namespace.c: constify struct path passed to a bunch of primitives (diff) | |
download | linux-f0bb5aaf2c51267c49ed5e2c6103df22acfe30f5.tar.xz linux-f0bb5aaf2c51267c49ed5e2c6103df22acfe30f5.zip |
vfs: misc struct path constification
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/namei.c')
-rw-r--r-- | fs/namei.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/namei.c b/fs/namei.c index 5b4eed221530..1c8f4386b03f 100644 --- a/fs/namei.c +++ b/fs/namei.c @@ -2895,7 +2895,7 @@ bool may_open_dev(const struct path *path) !(path->mnt->mnt_sb->s_iflags & SB_I_NODEV); } -static int may_open(struct path *path, int acc_mode, int flag) +static int may_open(const struct path *path, int acc_mode, int flag) { struct dentry *dentry = path->dentry; struct inode *inode = dentry->d_inode; @@ -2945,7 +2945,7 @@ static int may_open(struct path *path, int acc_mode, int flag) static int handle_truncate(struct file *filp) { - struct path *path = &filp->f_path; + const struct path *path = &filp->f_path; struct inode *inode = path->dentry->d_inode; int error = get_write_access(inode); if (error) |