From 54425a9faac7fbdbf777605404a9a8e35359eb1d Mon Sep 17 00:00:00 2001 From: Martin Hedenfal Date: Tue, 29 Jun 2010 02:54:21 +0000 Subject: don't overwrite the return code from validate_entry --- usr.sbin/ldapd/modify.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'usr.sbin/ldapd') diff --git a/usr.sbin/ldapd/modify.c b/usr.sbin/ldapd/modify.c index 79921dd14c2..12507c276d3 100644 --- a/usr.sbin/ldapd/modify.c +++ b/usr.sbin/ldapd/modify.c @@ -1,4 +1,4 @@ -/* $OpenBSD: modify.c,v 1.4 2010/06/29 02:45:46 martinh Exp $ */ +/* $OpenBSD: modify.c,v 1.5 2010/06/29 02:54:20 martinh Exp $ */ /* * Copyright (c) 2009, 2010 Martin Hedenfalk @@ -125,7 +125,7 @@ ldap_add(struct request *req) namespace_abort(ns); if (rc == LDAP_SUCCESS && errno == EEXIST) rc = LDAP_ALREADY_EXISTS; - else + else if (rc == LDAP_SUCCESS) rc = LDAP_OTHER; } else if (namespace_commit(ns) != 0) rc = LDAP_OTHER; -- cgit v1.2.3