ldap/servers/slapd/back-ldbm/ldbm_modify.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
New commits:
commit b721da8061074126db6028e819e629bc51c37784
Author: Noriko Hosoi <nhosoi(a)redhat.com>
Date: Tue Oct 7 12:12:28 2014 -0700
Ticket #47919 - ldbm_back_modify SLAPI_PLUGIN_BE_PRE_MODIFY_FN does not return even if
one of the preop plugins fails.
Bug Description: In ldbm_back_modify, if one of the be_preop plugins
called at SLAPI_PLUGIN_BE_PRE_MODIFY_FN fail, ldbm_back_modify does
not return there but go to the real modify operation.
Fix Description: If an error is returned from be_preop plugins in
ldbm_back_modify, it returns the error there and does not proceed
the modify operation.
https://fedorahosted.org/389/ticket/47919
Reviewed by mreynolds(a)redhat.com (Thank you, Mark!!)
(cherry picked from commit cb173814ec579fafbfef515738c16a986a9749cd)
(cherry picked from commit 17294432e95bdb30c6816cefa7be5035df818a43)
(cherry picked from commit 65c73b4f909903b46655aee020b2e82c0cd4cfd0)
diff --git a/ldap/servers/slapd/back-ldbm/ldbm_modify.c
b/ldap/servers/slapd/back-ldbm/ldbm_modify.c
index e6ccf20..5f6d14d 100644
--- a/ldap/servers/slapd/back-ldbm/ldbm_modify.c
+++ b/ldap/servers/slapd/back-ldbm/ldbm_modify.c
@@ -596,11 +596,11 @@ ldbm_back_modify( Slapi_PBlock *pb )
if (SLAPI_PLUGIN_NOOP == opreturn) {
not_an_error = 1;
rc = opreturn = LDAP_SUCCESS;
- goto error_return;
} else if (!opreturn) {
- opreturn = -1;
+ opreturn = SLAPI_PLUGIN_FAILURE;
slapi_pblock_set(pb, SLAPI_PLUGIN_OPRETURN, &opreturn);
}
+ goto error_return;
}
/* The Plugin may have messed about with some of the PBlock parameters... ie. mods */
slapi_pblock_get( pb, SLAPI_MODIFY_MODS, &mods );