diff options
author | Florian Obser <florian@cvs.openbsd.org> | 2017-07-28 12:58:53 +0000 |
---|---|---|
committer | Florian Obser <florian@cvs.openbsd.org> | 2017-07-28 12:58:53 +0000 |
commit | f08409edbde15cf46d323ae0453ceac18d464461 (patch) | |
tree | afe5dff1a53f2523eb2d22e055bcb83b2e655994 | |
parent | ea7e93ff64e753ea4f1146b5a817c5d39bc62ff0 (diff) |
One negation is enough; pointed out by clang.
OK gsoares who says that he forgot about the same diff for months and
that millert@ had OK'ed it.
-rw-r--r-- | usr.sbin/ldapd/modify.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.sbin/ldapd/modify.c b/usr.sbin/ldapd/modify.c index f5d9007faaa..eda202d9417 100644 --- a/usr.sbin/ldapd/modify.c +++ b/usr.sbin/ldapd/modify.c @@ -1,4 +1,4 @@ -/* $OpenBSD: modify.c,v 1.19 2017/02/11 20:40:03 guenther Exp $ */ +/* $OpenBSD: modify.c,v 1.20 2017/07/28 12:58:52 florian Exp $ */ /* * Copyright (c) 2009, 2010 Martin Hedenfalk <martin@bzero.se> @@ -132,7 +132,7 @@ ldap_add(struct request *req) return ldap_refer(req, dn, NULL, refs); } - if (!authorized(req->conn, ns, ACI_WRITE, dn, LDAP_SCOPE_BASE) != 0) + if (!authorized(req->conn, ns, ACI_WRITE, dn, LDAP_SCOPE_BASE)) return ldap_respond(req, LDAP_INSUFFICIENT_ACCESS); /* Check that we're not adding immutable attributes. @@ -242,7 +242,7 @@ ldap_modify(struct request *req) return ldap_refer(req, dn, NULL, refs); } - if (!authorized(req->conn, ns, ACI_WRITE, dn, LDAP_SCOPE_BASE) != 0) + if (!authorized(req->conn, ns, ACI_WRITE, dn, LDAP_SCOPE_BASE)) return ldap_respond(req, LDAP_INSUFFICIENT_ACCESS); if (namespace_begin(ns) == -1) { |