MDB_APPEND should only be used in tool mode

This commit is contained in:
Howard Chu 2012-04-09 05:18:44 -07:00
parent 9e6245f87e
commit 71843da2a7

View File

@ -190,11 +190,14 @@ mdb_dn2id_add(
rc = mdb_cursor_put( mcp, &key, &data, MDB_NODUPDATA );
if (rc == 0) {
int flag = MDB_NODUPDATA;
nid = e->e_id;
memcpy( ptr, &pid, sizeof( ID ));
d->nrdnlen[0] ^= 0x80;
rc = mdb_cursor_put( mcd, &key, &data, MDB_NODUPDATA|MDB_APPEND );
if (slapMode & SLAP_TOOL_MODE)
flag |= MDB_APPEND;
rc = mdb_cursor_put( mcd, &key, &data, flag );
}
fail: