audit.c : Code clean up
PATCH 1/1 audit.c : Code clean up
Fixed a coding style issue (unnecessary parentheses , unnecessary braces)
Signed-off-by Ameen-Ali <[email protected]>
--- kernel/audit.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
kernel/audit.c +2 -3
@@ -663,7 +663,7 @@ static int audit_netlink_ok(struct sk_buff *skb, u16 msg_type)case AUDIT_MAKE_EQUIV :/* Only support auditd and auditctl in initial pid namespace * for now. */ -if ((task_active_pid_ns (current) != &init_pid_ns)) +if (task_active_pid_ns (current) != &init_pid_ns)return -EPERM ;if (!netlink_capable (skb,CAP_AUDIT_CONTROL ))
@@ -1759,7 +1759,7 @@ void audit_log_name(struct audit_context *context, struct audit_names *n, }else audit_log_format (ab," name=(null)" ); -if (n->ino != (unsigned long )-1 ) { +if (n->ino != (unsigned long )-1 ) audit_log_format(ab, " inode=%lu" " dev=%02x:%02x mode=%#ho" " ouid=%u ogid=%u rdev=%02x:%02x",
@@ -1771,7 +1771,6 @@ void audit_log_name(struct audit_context *context, struct audit_names *n,from_kgid (&init_user_ns, n->gid),MAJOR (n->rdev), MINOR(n->rdev)); - }if (n->osid !=0 ) {char *ctx =NULL ;u32 len;
Signature · 1 line
2.1.0
Quoted 6 lines · Ameen Ali
Fixed a coding style issue (unnecessary parentheses , unnecessary braces)
Signed-off-by Ameen-Ali <[email protected]>--- kernel/audit.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
Merged into my next-queue branch, I'll push to audit#next once -rc1 is released.
Quoted 30 lines
kernel/audit.c +0
-0@@ -663,7 +663,7 @@ static int audit_netlink_ok(struct sk_buff *skb, u16
msg_type) caseAUDIT_MAKE_EQUIV:kernel/audit.c +1
-1/* Only support auditd and auditctl in initial pid namespace * for now. */ -if ((task_active_pid_ns (current) != &init_pid_ns)) +if (task_active_pid_ns (current) != &init_pid_ns)return -EPERM ;if (!netlink_capable (skb,CAP_AUDIT_CONTROL ))@@ -1759,7 +1759,7 @@ void audit_log_name(struct audit_context *context,struct
audit_names*n, } elsekernel/audit.c +1
-2audit_log_format (ab," name=(null)" ); -if (n->ino != (unsigned long )-1 ) { +if (n->ino != (unsigned long )-1 ) audit_log_format(ab, " inode=%lu" " dev=%02x:%02x mode=%#ho" " ouid=%u ogid=%u rdev=%02x:%02x",@@ -1771,7 +1771,6 @@ void audit_log_name(struct audit_context *context, struct audit_names *n, from_kgid(&init_user_ns, n->gid), MAJOR(n->rdev), MINOR(n->rdev)); - }if (n->osid !=0 ) {char *ctx =NULL ;u32 len;
Signature · 2 lines
paul moore www.paul-moore.com