svn commit: r208783 - head/lib/libc/posix1e
Edward Tomasz Napierala
trasz at FreeBSD.org
Thu Jun 3 14:16:58 UTC 2010
Author: trasz
Date: Thu Jun 3 14:16:58 2010
New Revision: 208783
URL: http://svn.freebsd.org/changeset/base/208783
Log:
The 'acl_cnt' field is unsigned; no point in checking if it's >= 0.
Found with: Coverity Prevent
CID: 6192
Modified:
head/lib/libc/posix1e/acl_entry.c
Modified: head/lib/libc/posix1e/acl_entry.c
==============================================================================
--- head/lib/libc/posix1e/acl_entry.c Thu Jun 3 14:15:08 2010 (r208782)
+++ head/lib/libc/posix1e/acl_entry.c Thu Jun 3 14:16:58 2010 (r208783)
@@ -55,8 +55,7 @@ acl_create_entry(acl_t *acl_p, acl_entry
* +1, because we are checking if there is space left for one more
* entry.
*/
- if ((acl_int->acl_cnt + 1 >= ACL_MAX_ENTRIES) ||
- (acl_int->acl_cnt < 0)) {
+ if (acl_int->acl_cnt + 1 >= ACL_MAX_ENTRIES) {
errno = EINVAL;
return (-1);
}
More information about the svn-src-head
mailing list