X-Git-Url: http://git.rot13.org/?a=blobdiff_plain;f=security%2Fselinux%2Favc.c;h=a300702da5276a41a5c86a68e389f5ebcacdc058;hb=e45d6634e57315f09f4522365146da523453f859;hp=53d6c7bbf56459f6aa7145a7c3649a754588abc1;hpb=f1dccedc8148026d9071c6805f7cb77374a9e56f;p=powerpc.git diff --git a/security/selinux/avc.c b/security/selinux/avc.c index 53d6c7bbf5..a300702da5 100644 --- a/security/selinux/avc.c +++ b/security/selinux/avc.c @@ -43,13 +43,11 @@ static const struct av_perm_to_string #undef S_ }; -#ifdef CONFIG_AUDIT static const char *class_to_string[] = { #define S_(s) s, #include "class_to_string.h" #undef S_ }; -#endif #define TB_(s) static const char * s [] = { #define TE_(s) }; @@ -802,7 +800,7 @@ out: int avc_ss_reset(u32 seqno) { struct avc_callback_node *c; - int i, rc = 0; + int i, rc = 0, tmprc; unsigned long flag; struct avc_node *node; @@ -815,15 +813,16 @@ int avc_ss_reset(u32 seqno) for (c = avc_callbacks; c; c = c->next) { if (c->events & AVC_CALLBACK_RESET) { - rc = c->callback(AVC_CALLBACK_RESET, - 0, 0, 0, 0, NULL); - if (rc) - goto out; + tmprc = c->callback(AVC_CALLBACK_RESET, + 0, 0, 0, 0, NULL); + /* save the first error encountered for the return + value and continue processing the callbacks */ + if (!rc) + rc = tmprc; } } avc_latest_notif_update(seqno, 0); -out: return rc; }