Skip to content
Snippets Groups Projects
Commit 6054463e authored by Hallvard Furuseth's avatar Hallvard Furuseth
Browse files

Minor cleanup:

Fix Statlog() formats, remove an implicit int, include <ctype.h> for isspace().
parent 0fe5da0f
No related branches found
No related tags found
No related merge requests found
......@@ -131,7 +131,7 @@ do_add( Connection *conn, Operation *op )
return rc;
}
Statslog( LDAP_DEBUG_STATS, "conn=%d op=%d ADD dn=\"%s\"\n",
Statslog( LDAP_DEBUG_STATS, "conn=%ld op=%d ADD dn=\"%s\"\n",
op->o_connid, op->o_opid, e->e_ndn, 0, 0 );
/*
......
......@@ -159,8 +159,8 @@ do_bind(
version, dn, method );
}
Statslog( LDAP_DEBUG_STATS, "conn=%d op=%d BIND dn=\"%s\" method=%d\n",
op->o_connid, op->o_opid, ndn, method, 0 );
Statslog( LDAP_DEBUG_STATS, "conn=%ld op=%d BIND dn=\"%s\" method=%ld\n",
op->o_connid, op->o_opid, ndn, (unsigned long) method, 0 );
if ( version < LDAP_VERSION_MIN || version > LDAP_VERSION_MAX ) {
Debug( LDAP_DEBUG_ANY, "unknown version %d\n", version, 0, 0 );
......
......@@ -84,7 +84,7 @@ do_compare(
Debug( LDAP_DEBUG_ARGS, "do_compare: dn (%s) attr (%s) value (%s)\n",
ndn, ava.ava_type, ava.ava_value.bv_val );
Statslog( LDAP_DEBUG_STATS, "conn=%d op=%d CMP dn=\"%s\" attr=\"%s\"\n",
Statslog( LDAP_DEBUG_STATS, "conn=%ld op=%d CMP dn=\"%s\" attr=\"%s\"\n",
op->o_connid, op->o_opid, ndn, ava.ava_type, 0 );
/*
......
......@@ -505,7 +505,7 @@ connection_destroy( Connection *c )
ber_pvt_sb_close( c->c_sb );
Statslog( LDAP_DEBUG_STATS,
"conn=%d fd=%d closed.\n",
"conn=%ld fd=%d closed.\n",
c->c_connid, sd, 0, 0, 0 );
}
......
......@@ -451,6 +451,7 @@ int slapd_daemon_init(char *urls, int port, int tls_port )
}
int
slapd_daemon_destroy(void)
{
connections_destroy();
......@@ -755,7 +756,7 @@ slapd_daemon_task(
}
Statslog( LDAP_DEBUG_STATS,
"daemon: conn=%d fd=%ld connection from %s (%s) accepted.\n",
"daemon: conn=%ld fd=%ld connection from %s (%s) accepted.\n",
id, (long) s,
peername,
slap_listeners[l]->sl_name,
......
......@@ -162,7 +162,7 @@ do_modify(
return rc;
}
Statslog( LDAP_DEBUG_STATS, "conn=%d op=%d MOD dn=\"%s\"\n",
Statslog( LDAP_DEBUG_STATS, "conn=%ld op=%d MOD dn=\"%s\"\n",
op->o_connid, op->o_opid, ndn, 0, 0 );
/*
......
......@@ -172,7 +172,7 @@ do_modrdn(
return rc;
}
Statslog( LDAP_DEBUG_STATS, "conn=%d op=%d MODRDN dn=\"%s\"\n",
Statslog( LDAP_DEBUG_STATS, "conn=%ld op=%d MODRDN dn=\"%s\"\n",
op->o_connid, op->o_opid, ndn, 0, 0 );
/*
......
......@@ -8,6 +8,7 @@
#include <ac/errno.h>
#include <ac/signal.h>
#include <ac/string.h>
#include <ac/ctype.h>
#include <ac/time.h>
#include <ac/unistd.h>
......
......@@ -157,7 +157,7 @@ do_search(
Debug( LDAP_DEBUG_ARGS, "\n", 0, 0, 0 );
Statslog( LDAP_DEBUG_STATS,
"conn=%d op=%d SRCH base=\"%s\" scope=%d filter=\"%s\"\n",
"conn=%ld op=%d SRCH base=\"%s\" scope=%d filter=\"%s\"\n",
op->o_connid, op->o_opid, base, scope, fstr );
if ( scope == LDAP_SCOPE_BASE ) {
......
......@@ -40,7 +40,7 @@ do_unbind(
* UnBindRequest ::= NULL
*/
Statslog( LDAP_DEBUG_STATS, "conn=%d op=%d UNBIND\n", op->o_connid,
Statslog( LDAP_DEBUG_STATS, "conn=%ld op=%d UNBIND\n", op->o_connid,
op->o_opid, 0, 0, 0 );
/* pass the unbind to all backends */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment