From: Hallvard Furuseth Date: Sun, 18 Sep 2011 19:49:25 +0000 (+0200) Subject: Cleanup ISO C compatibility for recent commits X-Git-Tag: OPENLDAP_REL_ENG_2_4_27~246 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=292860f0c68c196936cf86d206812b41259ec29d;p=openldap Cleanup ISO C compatibility for recent commits --- diff --git a/libraries/liblber/debug.c b/libraries/liblber/debug.c index cc38e85b44..7a1b29953f 100644 --- a/libraries/liblber/debug.c +++ b/libraries/liblber/debug.c @@ -62,7 +62,7 @@ void (lutil_debug)( int debug, int level, const char *fmt, ... ) } #endif - sprintf(buffer, "%08x ", time(0L)); + sprintf(buffer, "%08x ", (unsigned) time(0L)); va_start( vl, fmt ); vsnprintf( buffer+9, sizeof(buffer)-9, fmt, vl ); buffer[sizeof(buffer)-1] = '\0'; diff --git a/servers/slapd/overlays/pcache.c b/servers/slapd/overlays/pcache.c index 6875b19fa7..d27dcb7a0a 100644 --- a/servers/slapd/overlays/pcache.c +++ b/servers/slapd/overlays/pcache.c @@ -2908,9 +2908,9 @@ pcache_op_bind( /* OK, just bind locally */ if ( bi.bi_flags & BI_HASHED ) { + int delete = 0; BackendDB *be = op->o_bd; op->o_bd = &cm->db; - int delete = 0; Debug( pcache_debug, "pcache_op_bind: CACHED BIND for %s\n", op->o_req_dn.bv_val, 0, 0 ); diff --git a/servers/slapd/syncrepl.c b/servers/slapd/syncrepl.c index 204f064e97..0c4bb5b978 100644 --- a/servers/slapd/syncrepl.c +++ b/servers/slapd/syncrepl.c @@ -2077,8 +2077,12 @@ syncrepl_op_modify( Operation *op, SlapReply *rs ) Modifications *ml; int size, rc; SlapReply rs1 = {0}; - resolve_ctxt rx = { si, newlist }; - slap_callback cb = { NULL, syncrepl_resolve_cb, NULL, &rx }; + resolve_ctxt rx; + slap_callback cb = { NULL, syncrepl_resolve_cb, NULL, NULL }; + + rx.rx_si = si; + rx.rx_mods = newlist; + cb.sc_private = ℞ op2.o_tag = LDAP_REQ_SEARCH; op2.ors_scope = LDAP_SCOPE_SUBTREE;