libsmack: remove redundant check for clear flag form accesses_apply()
authorJarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Sun, 1 Dec 2013 15:03:55 +0000 (17:03 +0200)
committerJarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Mon, 2 Dec 2013 07:04:39 +0000 (09:04 +0200)
Signed-off-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
libsmack/libsmack.c

index 2d68089..6f1ba01 100644 (file)
@@ -689,7 +689,7 @@ static int accesses_apply(struct smack_accesses *handle, int clear)
                access_code_to_str(clear ? 0 : rule->allow_code, allow_str);
 
                if (rule->deny_code != -1 && !clear) {
-                       access_code_to_str(clear ? 0 : rule->deny_code, deny_str);
+                       access_code_to_str(rule->deny_code, deny_str);
 
                        fd = change_fd;
                        ret = snprintf(buf, LOAD_LEN + 1, KERNEL_MODIFY_FORMAT,