aboutsummaryrefslogtreecommitdiff
path: root/src/integration-tests
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2013-09-25 21:42:11 +0000
committerChristian Grothoff <christian@grothoff.org>2013-09-25 21:42:11 +0000
commit78ad97319349e9881653684f276dd620a0a423e9 (patch)
treecded8f0063f6848429706a36bd51174e62417b7e /src/integration-tests
parentb968c5926b205c3cdd467474753746ef21522b32 (diff)
downloadgnunet-78ad97319349e9881653684f276dd620a0a423e9.tar.gz
gnunet-78ad97319349e9881653684f276dd620a0a423e9.zip
-misc fixes based on cppcheck
Diffstat (limited to 'src/integration-tests')
-rw-r--r--src/integration-tests/connection_watchdog.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/src/integration-tests/connection_watchdog.c b/src/integration-tests/connection_watchdog.c
index e519f0f82..73c86d8e4 100644
--- a/src/integration-tests/connection_watchdog.c
+++ b/src/integration-tests/connection_watchdog.c
@@ -205,17 +205,18 @@ stats_check (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc);
205static int 205static int
206check_lowlevel_connections (int port, int protocol) 206check_lowlevel_connections (int port, int protocol)
207{ 207{
208#ifdef MINGW
209 /* not supported */
210 return count;
211#else
208 FILE *f; 212 FILE *f;
209 char * cmdline; 213 char * cmdline;
210 char * proto; 214 char * proto;
211 char line[1024]; 215 char line[1024];
212 int count = -1; 216 int count = -1;
213#ifdef MINGW
214 /* not supported */
215 return count;
216#else
217 217
218 switch (protocol) { 218 switch (protocol)
219 {
219 case tcp: 220 case tcp:
220 proto = "-t"; 221 proto = "-t";
221 break; 222 break;
@@ -252,11 +253,12 @@ check_lowlevel_connections (int port, int protocol)
252 { 253 {
253 /* read */ 254 /* read */
254 //printf ("%s", line); 255 //printf ("%s", line);
255 count ++; 256 count++;
256 } 257 }
257 258
258 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "%i TCP connections established with port %u\n", 259 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
259 count, port); 260 "%i TCP connections established with port %u\n",
261 count, port);
260 262
261 pclose (f); 263 pclose (f);
262 GNUNET_free (cmdline); 264 GNUNET_free (cmdline);