diff options
author | James Morris <jmorris@namei.org> | 2009-09-11 00:04:49 +0200 |
---|---|---|
committer | James Morris <jmorris@namei.org> | 2009-09-11 00:04:49 +0200 |
commit | a3c8b97396ef42edfb845788ba6f53b2a93ce980 (patch) | |
tree | 530c5bdbc534618311dab3e0af245835af56db0f /fs/namei.c | |
parent | Linux 2.6.31 (diff) | |
parent | binfmt_elf: fix PT_INTERP bss handling (diff) | |
download | linux-a3c8b97396ef42edfb845788ba6f53b2a93ce980.tar.xz linux-a3c8b97396ef42edfb845788ba6f53b2a93ce980.zip |
Merge branch 'next' into for-linus
Diffstat (limited to 'fs/namei.c')
-rw-r--r-- | fs/namei.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/fs/namei.c b/fs/namei.c index 1f13751693a5..fcfc5539252c 100644 --- a/fs/namei.c +++ b/fs/namei.c @@ -1533,9 +1533,11 @@ int may_open(struct path *path, int acc_mode, int flag) if (error) return error; - error = ima_path_check(path, - acc_mode & (MAY_READ | MAY_WRITE | MAY_EXEC), + error = ima_path_check(path, acc_mode ? + acc_mode & (MAY_READ | MAY_WRITE | MAY_EXEC) : + ACC_MODE(flag) & (MAY_READ | MAY_WRITE), IMA_COUNT_UPDATE); + if (error) return error; /* |