X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=servers%2Fslapd%2Fback-bdb%2Ftools.c;h=beb0048cecfd5b148e2c5f5a434b8e49d3c4e91a;hb=b60820ee696c09bad18fd04fdd982df7af15c6c3;hp=2d9f780a08eede00db4b7e24ff8462a725198b61;hpb=48685b7962e9c365752a7eaeaeda9785cdee7946;p=openldap diff --git a/servers/slapd/back-bdb/tools.c b/servers/slapd/back-bdb/tools.c index 2d9f780a08..beb0048cec 100644 --- a/servers/slapd/back-bdb/tools.c +++ b/servers/slapd/back-bdb/tools.c @@ -2,7 +2,7 @@ /* $OpenLDAP$ */ /* This work is part of OpenLDAP Software . * - * Copyright 2000-2012 The OpenLDAP Foundation. + * Copyright 2000-2015 The OpenLDAP Foundation. * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -832,6 +832,11 @@ int bdb_tool_entry_reindex( return -1; } + op.o_hdr = &ohdr; + op.o_bd = be; + op.o_tmpmemctx = NULL; + op.o_tmpmfuncs = &ch_mfuncs; + if (! (slapMode & SLAP_TOOL_QUICK)) { rc = TXN_BEGIN( bi->bi_dbenv, NULL, &tid, bi->bi_db_opflags ); if( rc != 0 ) { @@ -856,11 +861,6 @@ int bdb_tool_entry_reindex( "=> " LDAP_XSTRING(bdb_tool_entry_reindex) "( %ld, \"%s\" )\n", (long) id, e->e_dn, 0 ); - op.o_hdr = &ohdr; - op.o_bd = be; - op.o_tmpmemctx = NULL; - op.o_tmpmfuncs = &ch_mfuncs; - rc = bdb_tool_index_add( &op, tid, e ); done: