remove debugging stuff, fix for very small values of small world options
authorNathan S. Evans <evans@in.tum.de>
Tue, 12 Oct 2010 13:45:56 +0000 (13:45 +0000)
committerNathan S. Evans <evans@in.tum.de>
Tue, 12 Oct 2010 13:45:56 +0000 (13:45 +0000)
src/testing/test_testing_topology.c
src/testing/test_testing_topology_blacklist.c
src/testing/testing_group.c

index 83c96a4516610b585c30df3301659df83af9c2d8..dd8a164191d37eb8268aaaa93fff7c548d122fb9 100644 (file)
@@ -26,7 +26,7 @@
 #include "gnunet_core_service.h"
 #include "gnunet_os_lib.h"
 
-#define VERBOSE GNUNET_YES
+#define VERBOSE GNUNET_NO
 
 #define DELAY_FOR_LOGGING GNUNET_NO
 
@@ -709,8 +709,10 @@ topology_callback (void *cls,
 static void topology_creation_finished (void *cls,
                                         const char *emsg)
 {
+#if VERBOSE
   if (emsg == NULL)
     GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "All topology connections created successfully!\n");
+#endif
 }
 
 static void
index 4485319219a5800d5c4d515cd40b9938f2c4fa9e..8f9a469e5bb54b05a9a326fb2a90a0dce4e3e94a 100644 (file)
@@ -25,7 +25,7 @@
 #include "gnunet_testing_lib.h"
 #include "gnunet_core_service.h"
 
-#define VERBOSE GNUNET_YES
+#define VERBOSE GNUNET_NO
 
 /**
  * How long until we fail the whole testcase?
index abaeaaf11a16f111cf47438069302b105f9b959d..23ab2f9fe7f30f20ef0e23edf60a9d3407885c62 100644 (file)
@@ -1554,6 +1554,8 @@ create_small_world (struct GNUNET_TESTING_PeerGroup *pg, GNUNET_TESTING_Connecti
 #endif
   smallWorldConnections = 0;
   small_world_it = (unsigned int)(natLog * percentage);
+  if (small_world_it < 1)
+    small_world_it = 1;
   GNUNET_assert(small_world_it > 0 && small_world_it < (unsigned int)-1);
   for (i = 0; i < small_world_it; i++)
     {