aboutsummaryrefslogtreecommitdiff
path: root/src/transport
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2011-08-01 20:40:11 +0000
committerChristian Grothoff <christian@grothoff.org>2011-08-01 20:40:11 +0000
commit8ed5770729764ad93bca2514607cb7652cf0e65b (patch)
tree4cc24928d8ddf1aa4abb208b8f116b6d2053266c /src/transport
parent3de7831182e144ea960326e5efaaf1447d5e5ae9 (diff)
downloadgnunet-8ed5770729764ad93bca2514607cb7652cf0e65b.tar.gz
gnunet-8ed5770729764ad93bca2514607cb7652cf0e65b.zip
LRN: Fix debug logging in some transport tests
Diffstat (limited to 'src/transport')
-rw-r--r--src/transport/test_quota_compliance.c11
-rw-r--r--src/transport/test_transport_api_multiaddress.c49
2 files changed, 3 insertions, 57 deletions
diff --git a/src/transport/test_quota_compliance.c b/src/transport/test_quota_compliance.c
index 26d6f4bf6..0143772db 100644
--- a/src/transport/test_quota_compliance.c
+++ b/src/transport/test_quota_compliance.c
@@ -303,16 +303,9 @@ notify_ready (void *cls, size_t size, void *buf)
303 ret += sizeof (struct TestMessage); 303 ret += sizeof (struct TestMessage);
304 memset (&cbuf[ret], last_msg_sent, s - sizeof (struct TestMessage)); 304 memset (&cbuf[ret], last_msg_sent, s - sizeof (struct TestMessage));
305 ret += s - sizeof (struct TestMessage); 305 ret += s - sizeof (struct TestMessage);
306#if DEBUG_MEASUREMENT
307 if (n % 5000 == 0)
308 {
309 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
310 "Sending message %u\n",n);
311 }
312#endif
313 306
314 /* GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 307 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
315 "Sending message %u\n",last_msg_sent);*/ 308 "Sending message %u\n",last_msg_sent);
316 309
317 s = get_size (); 310 s = get_size ();
318 if (0 == GNUNET_CRYPTO_random_u32 (GNUNET_CRYPTO_QUALITY_WEAK, 16)) 311 if (0 == GNUNET_CRYPTO_random_u32 (GNUNET_CRYPTO_QUALITY_WEAK, 16))
diff --git a/src/transport/test_transport_api_multiaddress.c b/src/transport/test_transport_api_multiaddress.c
index f56d7c026..b2ac507d2 100644
--- a/src/transport/test_transport_api_multiaddress.c
+++ b/src/transport/test_transport_api_multiaddress.c
@@ -228,54 +228,7 @@ setup_peer (struct PeerContext *p,
228 p->arm_proc = GNUNET_OS_start_process (NULL, NULL, "gnunet-service-arm", 228 p->arm_proc = GNUNET_OS_start_process (NULL, NULL, "gnunet-service-arm",
229 "gnunet-service-arm", 229 "gnunet-service-arm",
230#if VERBOSE_ARM 230#if VERBOSE_ARM
231 231 "-L", "DEBUG",
232 if (is_https)
233 {
234 struct stat sbuf;
235 if (0 == stat (cert_file_p1, &sbuf ))
236 {
237 if (0 == remove(cert_file_p1))
238 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
239 "Successfully removed existing certificate file `%s'\n",cert_file_p1);
240 else
241 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
242 "Failed to remove certfile `%s'\n",cert_file_p1);
243 }
244
245 if (0 == stat (key_file_p1, &sbuf ))
246 {
247 if (0 == remove(key_file_p1))
248 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
249 "Successfully removed private key file `%s'\n",key_file_p1);
250 else
251 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
252 "Failed to private key file `%s'\n",key_file_p1);
253 }
254
255 if (0 == stat (cert_file_p2, &sbuf ))
256 {
257 if (0 == remove(cert_file_p2))
258 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
259 "Successfully removed existing certificate file `%s'\n",cert_file_p2);
260 else
261 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
262 "Failed to remove certfile `%s'\n",cert_file_p2);
263 }
264
265 if (0 == stat (key_file_p2, &sbuf ))
266 {
267 if (0 == remove(key_file_p2))
268 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
269 "Successfully removed private key file `%s'\n",key_file_p2);
270 else
271 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
272 "Failed to private key file `%s'\n",key_file_p2);
273 }
274 GNUNET_free(key_file_p1);
275 GNUNET_free(key_file_p2);
276 GNUNET_free(cert_file_p1);
277 GNUNET_free(cert_file_p2);
278 } "-L", "DEBUG",
279#endif 232#endif
280 "-c", cfgname, NULL); 233 "-c", cfgname, NULL);
281#endif 234#endif