[apparmor] [patch 05/12] Fix segfault in af_unix rule processing
john.johansen at canonical.com
john.johansen at canonical.com
Tue Aug 26 00:06:10 UTC 2014
This patch fixes a segfault that was occurring in testing over the
weekend. The problem existed in the original patch that adds af_unix
rules (patch 06), but this patch applies at the end of the sequence
after the conversion from 'path' to 'addr' occurs, to simplify things a
bit.
Signed-off-by: Steve Beattie <steve at nxnw.org>
Acked-by: John Johansen <john.johansen at canonical.com>
---
parser/af_unix.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: b/parser/af_unix.cc
===================================================================
--- a/parser/af_unix.cc
+++ b/parser/af_unix.cc
@@ -83,7 +83,7 @@ void unix_rule::move_peer_conditionals(s
}
if (strcmp(ent->name, "addr") == 0) {
move_conditional_value("unix", &peer_addr, ent);
- if (peer_addr[0] != '@' && strcmp(addr, "none") != 0)
+ if (peer_addr[0] != '@' && strcmp(peer_addr, "none") != 0)
yyerror("unix rule: invalid value for addr='%s'\n", peer_addr);
}
}
More information about the AppArmor
mailing list