Break out of FSAL_ACE4_PERM_CONTINUE if deny blocks all remaining mask bits
Signed-off-by: Frank S. Filz <ffilz@us.ibm.com>
diff --git a/src/FSAL/access_check.c b/src/FSAL/access_check.c
index 3501d77..18079cc 100644
--- a/src/FSAL/access_check.c
+++ b/src/FSAL/access_check.c
@@ -484,6 +484,13 @@
}
missing_access &= ~(pace->perm & missing_access);
+
+ /* If this DENY ACE blocked the last remaining requested access
+ * bits, break out of the loop because we're done and don't
+ * want to evaluate any more ACEs.
+ */
+ if(!missing_access)
+ break;
}
}
}