mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-01-12 10:54:48 +08:00
ITS#7402 fix potential txn leak in online indexer
This commit is contained in:
parent
48f6a47c1e
commit
c2783b9c5e
@ -284,18 +284,17 @@ bdb_online_index( void *ctx, void *arg )
|
||||
}
|
||||
if ( ei->bei_e ) {
|
||||
rc = bdb_index_entry( op, txn, BDB_INDEX_UPDATE_OP, ei->bei_e );
|
||||
if ( rc == DB_LOCK_DEADLOCK ) {
|
||||
if ( rc ) {
|
||||
TXN_ABORT( txn );
|
||||
if ( rc == DB_LOCK_DEADLOCK ) {
|
||||
ldap_pvt_thread_yield();
|
||||
continue;
|
||||
}
|
||||
if ( rc == 0 ) {
|
||||
break;
|
||||
}
|
||||
rc = TXN_COMMIT( txn, 0 );
|
||||
txn = NULL;
|
||||
}
|
||||
if ( rc )
|
||||
break;
|
||||
}
|
||||
id++;
|
||||
getnext = 1;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user