mirror of
https://git.openldap.org/openldap/openldap.git
synced 2024-12-21 03:10:25 +08:00
set return code
This commit is contained in:
parent
40622232f7
commit
cd41bb1a06
@ -107,10 +107,12 @@ ldap_back_modify(
|
||||
|
||||
mods = (LDAPMod *)ch_malloc(i*sizeof(LDAPMod));
|
||||
if (mods == NULL) {
|
||||
rc = LDAP_NO_MEMORY;
|
||||
goto cleanup;
|
||||
}
|
||||
modv = (LDAPMod **)ch_malloc((i+1)*sizeof(LDAPMod *));
|
||||
if (modv == NULL) {
|
||||
rc = LDAP_NO_MEMORY;
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
@ -167,10 +169,12 @@ cleanup:;
|
||||
#ifdef ENABLE_REWRITE
|
||||
}
|
||||
#endif /* ENABLE_REWRITE */
|
||||
for (i=0; modv[i]; i++)
|
||||
for (i=0; modv[i]; i++) {
|
||||
ch_free(modv[i]->mod_bvalues);
|
||||
ch_free(mods);
|
||||
ch_free(modv);
|
||||
return( ldap_back_op_result( li, lc, conn, op, msgid, rc, 1 ));
|
||||
}
|
||||
ch_free( mods );
|
||||
ch_free( modv );
|
||||
|
||||
return ldap_back_op_result( li, lc, conn, op, msgid, rc, 1 );
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user