Skip to content
Snippets Groups Projects
Commit 5f7505f0 authored by Howard Chu's avatar Howard Chu Committed by Quanah Gibson-Mount
Browse files

ITS#7402 fix potential txn leak in online indexer

parent 3249c680
No related branches found
No related tags found
No related merge requests found
......@@ -284,17 +284,16 @@ 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 );
ldap_pvt_thread_yield();
continue;
}
if ( rc == 0 ) {
rc = TXN_COMMIT( txn, 0 );
txn = NULL;
}
if ( rc )
if ( rc == DB_LOCK_DEADLOCK ) {
ldap_pvt_thread_yield();
continue;
}
break;
}
rc = TXN_COMMIT( txn, 0 );
txn = NULL;
}
id++;
getnext = 1;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment