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

ITS#7657 back-mdb improve alias deref

Don't search for scopes of entries with no children
parent e224920e
No related branches found
No related tags found
No related merge requests found
......@@ -641,6 +641,22 @@ mdb_idscope(
rc = mdb_cursor_open( txn, dbi, &cursor );
if ( rc ) return rc;
/* first see if base has any children at all */
key.mv_data = &base;
rc = mdb_cursor_get( cursor, &key, &data, MDB_SET );
if ( rc ) {
goto leave;
}
{
size_t dkids;
rc = mdb_cursor_count( cursor, &dkids );
if ( rc == 0 ) {
if ( dkids < 2 ) {
goto leave;
}
}
}
ida = mdb_idl_first( ids, &cid );
/* Don't bother moving out of ids if it's a range */
......
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