]>
Commit | Line | Data |
---|---|---|
daaa955e AM |
1 | From 4b56e146905bbad2c79ea92e3f49e210ca527572 Mon Sep 17 00:00:00 2001 |
2 | From: John Johansen <john.johansen@canonical.com> | |
3 | Date: Mon, 31 Jul 2017 23:44:37 -0700 | |
4 | Subject: [PATCH 05/17] apparmor: Redundant condition: prev_ns. in | |
5 | [label.c:1498] | |
6 | ||
7 | Reported-by: David Binderman <dcb314@hotmail.com> | |
8 | Signed-off-by: John Johansen <john.johansen@canonical.com> | |
9 | (cherry picked from commit d323d2c17cfcc54b6845bfc1d13bca5cef210fc7) | |
10 | --- | |
11 | security/apparmor/label.c | 2 +- | |
12 | 1 file changed, 1 insertion(+), 1 deletion(-) | |
13 | ||
14 | diff --git a/security/apparmor/label.c b/security/apparmor/label.c | |
15 | index e052eaba1cf6..e324f4df3e34 100644 | |
16 | --- a/security/apparmor/label.c | |
17 | +++ b/security/apparmor/label.c | |
18 | @@ -1495,7 +1495,7 @@ static int aa_profile_snxprint(char *str, size_t size, struct aa_ns *view, | |
19 | view = profiles_ns(profile); | |
20 | ||
21 | if (view != profile->ns && | |
22 | - (!prev_ns || (prev_ns && *prev_ns != profile->ns))) { | |
23 | + (!prev_ns || (*prev_ns != profile->ns))) { | |
24 | if (prev_ns) | |
25 | *prev_ns = profile->ns; | |
26 | ns_name = aa_ns_name(view, profile->ns, | |
27 | -- | |
28 | 2.11.0 | |
29 |