From: Hallvard Furuseth Date: Mon, 13 Oct 2008 08:35:31 +0000 (+0000) Subject: Warning cleanup: signed meets unsigned. X-Git-Tag: ACLCHECK_0~1259 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=6f39252bd0f16ce4f5918b27aea0794ec3333a91;p=openldap Warning cleanup: signed meets unsigned. --- diff --git a/servers/slapd/back-bdb/back-bdb.h b/servers/slapd/back-bdb/back-bdb.h index 19c30cc5e1..6493a4583c 100644 --- a/servers/slapd/back-bdb/back-bdb.h +++ b/servers/slapd/back-bdb/back-bdb.h @@ -332,7 +332,7 @@ extern int __db_logmsg(const DB_ENV *env, DB_TXN *txn, const char *op, u_int32_t /* Copy a pointer "src" to a pointer "dst" from big-endian to native order */ #define BDB_DISK2ID( src, dst ) \ - do { int i0; ID tmp = 0; unsigned char *_p; \ + do { unsigned i0; ID tmp = 0; unsigned char *_p; \ _p = (unsigned char *)(src); \ for ( i0=0; i0= bdb->bi_cache.c_minfree ) { + if ( (unsigned) count >= bdb->bi_cache.c_minfree ) { ldap_pvt_thread_mutex_lock( &bdb->bi_cache.c_count_mutex ); bdb->bi_cache.c_cursize -= count; ldap_pvt_thread_mutex_unlock( &bdb->bi_cache.c_count_mutex ); diff --git a/servers/slapd/back-bdb/monitor.c b/servers/slapd/back-bdb/monitor.c index 7421cb1cd4..5f7134043b 100644 --- a/servers/slapd/back-bdb/monitor.c +++ b/servers/slapd/back-bdb/monitor.c @@ -551,9 +551,9 @@ bdb_monitor_bitmask2key( slap_mask_t bitmask ) { int key; - for ( key = 0; key < 8*sizeof(slap_mask_t) && !( bitmask & 0x1U ); key++ ) { + for ( key = 0; key < 8 * (int)sizeof(slap_mask_t) && !( bitmask & 0x1U ); + key++ ) bitmask >>= 1; - } return key; } diff --git a/servers/slapd/back-bdb/tools.c b/servers/slapd/back-bdb/tools.c index eb09962c78..66b2e9a32f 100644 --- a/servers/slapd/back-bdb/tools.c +++ b/servers/slapd/back-bdb/tools.c @@ -395,13 +395,12 @@ static int bdb_tool_next_id( holes[nholes++].id = e->e_id; } } else if ( !hole ) { - unsigned i; + unsigned i, j; e->e_id = ei->bei_id; for ( i=0; ie_id ) { - int j; free(holes[i].dn.bv_val); for (j=i;j