From: Luke Howard Date: Mon, 25 Jul 2005 10:24:02 +0000 (+0000) Subject: Use SLAPI_LOG_OPERATION instead of private flag X-Git-Tag: OPENLDAP_AC_BP~212 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=93540e339ae3fedf4dabc5fcdcc53c7e2de3ce63;p=openldap Use SLAPI_LOG_OPERATION instead of private flag --- diff --git a/servers/slapd/slapi/slapi.h b/servers/slapd/slapi/slapi.h index 07f7c59756..6f0e87163d 100644 --- a/servers/slapd/slapi/slapi.h +++ b/servers/slapd/slapi/slapi.h @@ -154,9 +154,6 @@ struct slapi_pblock { #define SLAPI_DB2LDIF_PRINTKEY 183 -#define SLAPI_PARENT_TXN 190 -#define SLAPI_TXN 191 - #define SLAPI_CHANGENUMBER 197 #define SLAPI_LOG_OPERATION 198 diff --git a/servers/slapd/slapi/slapi_ops.c b/servers/slapd/slapi/slapi_ops.c index ae6dcb3b32..8f1fb2a908 100644 --- a/servers/slapd/slapi/slapi_ops.c +++ b/servers/slapd/slapi/slapi_ops.c @@ -751,9 +751,8 @@ slapi_modify_internal( pb = slapi_pblock_new(); - slapi_modify_internal_set_pb( pb, ldn, mods, controls, NULL, NULL, - log_change ? SLAPI_OP_FLAG_LOG_CHANGE : 0 ); - + slapi_modify_internal_set_pb( pb, ldn, mods, controls, NULL, NULL, 0 ); + slapi_pblock_set( pb, SLAPI_LOG_OPERATION, (void *)log_change ); slapi_modify_internal_pb( pb ); return pb; @@ -783,15 +782,14 @@ slapi_add_internal( char * dn, LDAPMod **attrs, LDAPControl **controls, - int log_changes ) + int log_change ) { Slapi_PBlock *pb; pb = slapi_pblock_new(); - slapi_add_internal_set_pb( pb, dn, attrs, controls, NULL, - log_changes ? SLAPI_OP_FLAG_LOG_CHANGE : 0 ); - + slapi_add_internal_set_pb( pb, dn, attrs, controls, NULL, 0); + slapi_pblock_set( pb, SLAPI_LOG_OPERATION, (void *)log_change ); slapi_add_internal_pb( pb ); return pb; @@ -816,15 +814,14 @@ Slapi_PBlock * slapi_add_entry_internal( Slapi_Entry *e, LDAPControl **controls, - int log_changes ) + int log_change ) { Slapi_PBlock *pb; pb = slapi_pblock_new(); - slapi_add_entry_internal_set_pb( pb, e, controls, NULL, - log_changes ? SLAPI_OP_FLAG_LOG_CHANGE : 0 ); - + slapi_add_entry_internal_set_pb( pb, e, controls, NULL, 0 ); + slapi_pblock_set( pb, SLAPI_LOG_OPERATION, (void *)log_change ); slapi_add_internal_pb( pb ); return pb; @@ -878,9 +875,8 @@ slapi_modrdn_internal( pb = slapi_pblock_new (); slapi_rename_internal_set_pb( pb, olddn, lnewrdn, NULL, - deloldrdn, controls, NULL, NULL, - log_change ? SLAPI_OP_FLAG_LOG_CHANGE : 0 ); - + deloldrdn, controls, NULL, NULL, 0 ); + slapi_pblock_set( pb, SLAPI_LOG_OPERATION, (void *)log_change ); slapi_modrdn_internal_pb( pb ); return pb; @@ -923,9 +919,8 @@ slapi_delete_internal( pb = slapi_pblock_new(); - slapi_delete_internal_set_pb( pb, ldn, controls, NULL, NULL, - log_change ? SLAPI_OP_FLAG_LOG_CHANGE : 0 ); - + slapi_delete_internal_set_pb( pb, ldn, controls, NULL, NULL, 0 ); + slapi_pblock_set( pb, SLAPI_LOG_OPERATION, (void *)log_change ); slapi_delete_internal_pb( pb ); return pb;