diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2012-11-16 20:53:36 -0500 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2012-11-16 20:53:36 -0500 |
commit | 6929039761a3414e5c71448eb3dcc1d82fc1891d (patch) | |
tree | 49b349170dd93821c2d515fee3931a4023da35da /security/selinux/hooks.c | |
parent | e0fd18ce1169595df929373cad2ae9b00b2289c2 (diff) | |
parent | 6ba1bc826d160fe4f32bcb188687dcca4bdfaf3d (diff) |
Merge commit '6ba1bc826d160fe4f32bcb188687dcca4bdfaf3d' into arch-arm64
Backmerge from mainline commit that introduced a trivial conflict in
arch/arm64/kernel/process.c - a bunch of functions removed next to the
place where kernel_thread() used to be.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'security/selinux/hooks.c')
-rw-r--r-- | security/selinux/hooks.c | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c index 24ab4148547c..61a53367d029 100644 --- a/security/selinux/hooks.c +++ b/security/selinux/hooks.c | |||
@@ -2132,18 +2132,14 @@ static inline void flush_unauthorized_files(const struct cred *cred, | |||
2132 | return; | 2132 | return; |
2133 | 2133 | ||
2134 | devnull = dentry_open(&selinux_null, O_RDWR, cred); | 2134 | devnull = dentry_open(&selinux_null, O_RDWR, cred); |
2135 | if (!IS_ERR(devnull)) { | 2135 | if (IS_ERR(devnull)) |
2136 | /* replace all the matching ones with this */ | 2136 | devnull = NULL; |
2137 | do { | 2137 | /* replace all the matching ones with this */ |
2138 | replace_fd(n - 1, get_file(devnull), 0); | 2138 | do { |
2139 | } while ((n = iterate_fd(files, n, match_file, cred)) != 0); | 2139 | replace_fd(n - 1, devnull, 0); |
2140 | } while ((n = iterate_fd(files, n, match_file, cred)) != 0); | ||
2141 | if (devnull) | ||
2140 | fput(devnull); | 2142 | fput(devnull); |
2141 | } else { | ||
2142 | /* just close all the matching ones */ | ||
2143 | do { | ||
2144 | replace_fd(n - 1, NULL, 0); | ||
2145 | } while ((n = iterate_fd(files, n, match_file, cred)) != 0); | ||
2146 | } | ||
2147 | } | 2143 | } |
2148 | 2144 | ||
2149 | /* | 2145 | /* |