mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-04-12 15:10:31 +08:00
ITS#2348 additional check from HEAD
This commit is contained in:
parent
04382bb204
commit
0e5870cd47
@ -480,6 +480,12 @@ idl_insert_key(
|
||||
/* select the block to try inserting into *//* XXX linear search XXX */
|
||||
for ( i = 0; !ID_BLOCK_NOID(idl, i) && id > ID_BLOCK_ID(idl, i); i++ )
|
||||
; /* NULL */
|
||||
|
||||
/* The ID already exists in the IDL, no insert needed */
|
||||
if ( ID_BLOCK_ID( idl, i ) == id ) {
|
||||
idl_free( idl );
|
||||
return 0;
|
||||
}
|
||||
|
||||
if ( i != 0 ) {
|
||||
i--;
|
||||
|
Loading…
x
Reference in New Issue
Block a user