cleanup & more

This commit is contained in:
Pierangelo Masarati 2003-04-05 09:57:21 +00:00
parent 3814b5f1a1
commit b2075ea932
2 changed files with 10 additions and 8 deletions

View File

@ -179,6 +179,8 @@ int bdb_idl_fetch_key(
DBT *key, DBT *key,
ID *ids ); ID *ids );
int bdb_idl_insert( ID *ids, ID id );
int bdb_idl_insert_key( int bdb_idl_insert_key(
BackendDB *be, BackendDB *be,
DB *db, DB *db,

View File

@ -46,7 +46,6 @@ static Entry * deref_base (
{ {
struct bdb_info *bdb = (struct bdb_info *) be->be_private; struct bdb_info *bdb = (struct bdb_info *) be->be_private;
struct berval ndn; struct berval ndn;
unsigned x;
DB_LOCK lockr; DB_LOCK lockr;
rs->sr_err = LDAP_ALIAS_DEREF_PROBLEM; rs->sr_err = LDAP_ALIAS_DEREF_PROBLEM;
@ -356,7 +355,9 @@ int bdb_search( Operation *op, SlapReply *rs )
Filter cookief, csnfnot, csnfeq, csnfand, csnfge; Filter cookief, csnfnot, csnfeq, csnfand, csnfge;
AttributeAssertion aa_ge, aa_eq; AttributeAssertion aa_ge, aa_eq;
int entry_count = 0; int entry_count = 0;
#if 0
struct berval entrycsn_bv = { 0, NULL }; struct berval entrycsn_bv = { 0, NULL };
#endif
struct berval latest_entrycsn_bv = { 0, NULL }; struct berval latest_entrycsn_bv = { 0, NULL };
LDAPControl *ctrls[SLAP_SEARCH_MAX_CTRLS]; LDAPControl *ctrls[SLAP_SEARCH_MAX_CTRLS];
int num_ctrls = 0; int num_ctrls = 0;
@ -1067,7 +1068,8 @@ id2entry_retry:
#endif #endif
if (e) { if (e) {
int result; /* safe default */
int result = -1;
#if 0 /* noop is masked SLAP_CTRL_UPDATE */ #if 0 /* noop is masked SLAP_CTRL_UPDATE */
if( op->o_noop ) { if( op->o_noop ) {
@ -1421,7 +1423,7 @@ static void *search_stack(
if ( !ret ) { if ( !ret ) {
ret = ch_malloc( bdb->bi_search_stack_depth * BDB_IDL_UM_SIZE ret = ch_malloc( bdb->bi_search_stack_depth * BDB_IDL_UM_SIZE
* sizeof ID ); * sizeof( ID ) );
if ( op->o_threadctx ) { if ( op->o_threadctx ) {
ldap_pvt_thread_pool_setkey( op->o_threadctx, search_stack, ldap_pvt_thread_pool_setkey( op->o_threadctx, search_stack,
ret, search_stack_free ); ret, search_stack_free );
@ -1641,7 +1643,6 @@ bdb_build_lcup_update_ctrl(
Attribute* a; Attribute* a;
int ret; int ret;
int res; int res;
int rc;
const char *text = NULL; const char *text = NULL;
char berbuf[LBER_ELEMENT_SIZEOF]; char berbuf[LBER_ELEMENT_SIZEOF];
@ -1732,7 +1733,7 @@ bdb_build_lcup_done_ctrl(
int num_ctrls, int num_ctrls,
struct berval *latest_entrycsn_bv ) struct berval *latest_entrycsn_bv )
{ {
int ret, rc; int ret;
char berbuf[LBER_ELEMENT_SIZEOF]; char berbuf[LBER_ELEMENT_SIZEOF];
BerElement *ber = (BerElement *)berbuf; BerElement *ber = (BerElement *)berbuf;
@ -1780,7 +1781,6 @@ bdb_build_sync_state_ctrl(
Attribute* a; Attribute* a;
int ret; int ret;
int res; int res;
int rc;
const char *text = NULL; const char *text = NULL;
char berbuf[LBER_ELEMENT_SIZEOF]; char berbuf[LBER_ELEMENT_SIZEOF];
@ -1871,7 +1871,7 @@ bdb_build_sync_done_ctrl(
int send_cookie, int send_cookie,
struct berval *latest_entrycsn_bv ) struct berval *latest_entrycsn_bv )
{ {
int ret,rc; int ret;
char berbuf[LBER_ELEMENT_SIZEOF]; char berbuf[LBER_ELEMENT_SIZEOF];
BerElement *ber = (BerElement *)berbuf; BerElement *ber = (BerElement *)berbuf;
@ -1919,7 +1919,7 @@ bdb_send_ldap_intermediate(
BerElement *ber = (BerElement *)berbuf; BerElement *ber = (BerElement *)berbuf;
struct berval rspdata; struct berval rspdata;
int ret, rc; int ret;
ber_init2( ber, NULL, LBER_USE_DER ); ber_init2( ber, NULL, LBER_USE_DER );