From: Pekka Riikonen Date: Wed, 22 Jan 2003 09:23:57 +0000 (+0000) Subject: More information dumping in SIGUSR1 in debug mode. X-Git-Tag: silc.server.0.9.12~5 X-Git-Url: http://git.silcnet.org/gitweb/?p=silc.git;a=commitdiff_plain;h=fd9bc32c979540ccdc07a48e723f8dd66d9fa913 More information dumping in SIGUSR1 in debug mode. --- diff --git a/apps/silcd/silcd.c b/apps/silcd/silcd.c index 7327758f..7b37ac6a 100644 --- a/apps/silcd/silcd.c +++ b/apps/silcd/silcd.c @@ -320,6 +320,23 @@ SILC_TASK_CALLBACK(dump_stats) fprintf(fdd, " primary router : %s\n", silcd->router->server_name ? silcd->router->server_name : ""); + /* Dump socket connections */ + { + int i; + SilcSocketConnection s; + + fprintf(fdd, "\nDumping socket connections\n"); + for (i = 0; i < silcd->config->param.connections_max; i++) { + s = silcd->sockets[i]; + if (!s) + continue; + fprintf(fdd, " %d: host %s ip %s port %d type %d flags %ul\n", + s->sock, s->hostname ? s->hostname : "N/A", + s->ip ? s->ip : "N/A", s->port, s->type, + (unsigned int)s->flags); + } + } + /* Dump lists */ { SilcIDCacheList list = NULL;