diff options
Diffstat (limited to 'fs/exec.c')
-rw-r--r-- | fs/exec.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -135,7 +135,7 @@ asmlinkage long sys_uselib(const char __user * library) | |||
135 | if (!S_ISREG(nd.dentry->d_inode->i_mode)) | 135 | if (!S_ISREG(nd.dentry->d_inode->i_mode)) |
136 | goto exit; | 136 | goto exit; |
137 | 137 | ||
138 | error = permission(nd.dentry->d_inode, MAY_READ | MAY_EXEC, &nd); | 138 | error = vfs_permission(&nd, MAY_READ | MAY_EXEC); |
139 | if (error) | 139 | if (error) |
140 | goto exit; | 140 | goto exit; |
141 | 141 | ||
@@ -495,7 +495,7 @@ struct file *open_exec(const char *name) | |||
495 | file = ERR_PTR(-EACCES); | 495 | file = ERR_PTR(-EACCES); |
496 | if (!(nd.mnt->mnt_flags & MNT_NOEXEC) && | 496 | if (!(nd.mnt->mnt_flags & MNT_NOEXEC) && |
497 | S_ISREG(inode->i_mode)) { | 497 | S_ISREG(inode->i_mode)) { |
498 | int err = permission(inode, MAY_EXEC, &nd); | 498 | int err = vfs_permission(&nd, MAY_EXEC); |
499 | if (!err && !(inode->i_mode & 0111)) | 499 | if (!err && !(inode->i_mode & 0111)) |
500 | err = -EACCES; | 500 | err = -EACCES; |
501 | file = ERR_PTR(err); | 501 | file = ERR_PTR(err); |