mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-01-06 10:46:21 +08:00
Fixed exit code processing. passwd.c never committed its password change
tranasaction.
This commit is contained in:
parent
763faf21b1
commit
78066c08c0
@ -258,7 +258,8 @@ retry: rc = txn_abort( ltid );
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* attribute indexes */
|
/* attribute indexes */
|
||||||
if ( bdb_index_entry_add( be, ltid, e, e->e_attrs ) != LDAP_SUCCESS ) {
|
rc = bdb_index_entry_add( be, ltid, e, e->e_attrs );
|
||||||
|
if ( rc != LDAP_SUCCESS ) {
|
||||||
Debug( LDAP_DEBUG_TRACE, "bdb_add: index_entry_add failed\n",
|
Debug( LDAP_DEBUG_TRACE, "bdb_add: index_entry_add failed\n",
|
||||||
0, 0, 0 );
|
0, 0, 0 );
|
||||||
switch( rc ) {
|
switch( rc ) {
|
||||||
|
@ -265,7 +265,8 @@ retry: /* transaction retry */
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* delete from id2entry */
|
/* delete from id2entry */
|
||||||
if ( bdb_id2entry_delete( be, ltid, e->e_id ) != 0 ) {
|
rc = bdb_id2entry_delete( be, ltid, e->e_id );
|
||||||
|
if ( rc != 0 ) {
|
||||||
switch( rc ) {
|
switch( rc ) {
|
||||||
case DB_LOCK_DEADLOCK:
|
case DB_LOCK_DEADLOCK:
|
||||||
case DB_LOCK_NOTGRANTED:
|
case DB_LOCK_NOTGRANTED:
|
||||||
|
@ -195,6 +195,13 @@ retry: /* transaction retry */
|
|||||||
}
|
}
|
||||||
*text = "entry update failed";
|
*text = "entry update failed";
|
||||||
rc = LDAP_OTHER;
|
rc = LDAP_OTHER;
|
||||||
|
} else
|
||||||
|
{
|
||||||
|
rc = txn_commit( ltid, 0 );
|
||||||
|
ltid = NULL;
|
||||||
|
op->o_private = NULL;
|
||||||
|
if (rc)
|
||||||
|
*text = "commit failed";
|
||||||
}
|
}
|
||||||
|
|
||||||
done:
|
done:
|
||||||
|
Loading…
Reference in New Issue
Block a user