X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=src%2Frps%2Ftest_rps.c;h=92d8c12ea5a1ae46ccbe826d75542e01def01932;hb=7a5a724a6f96baf80d2226326124aa01c58ad3fe;hp=e7b82458a016eb848c3047c6b7f4ce29b0e1ef7a;hpb=fb3a42054245e0ae84a73a7e71b4973beb229108;p=oweals%2Fgnunet.git diff --git a/src/rps/test_rps.c b/src/rps/test_rps.c index e7b82458a..92d8c12ea 100644 --- a/src/rps/test_rps.c +++ b/src/rps/test_rps.c @@ -841,6 +841,13 @@ seed_peers (void *cls) unsigned int amount; unsigned int i; + if (GNUNET_YES == in_shutdown || GNUNET_YES == post_test) + { + return; + } + + GNUNET_assert (NULL != peer->rps_handle); + // TODO if malicious don't seed mal peers amount = round (.5 * num_peers); @@ -998,9 +1005,11 @@ rps_connect_adapter (void *cls, struct GNUNET_RPS_Handle *h; h = GNUNET_RPS_connect (cfg); + GNUNET_assert (NULL != h); if (NULL != cur_test_run.pre_test) cur_test_run.pre_test (cls, h); + GNUNET_assert (NULL != h); return h; } @@ -2841,7 +2850,7 @@ main (int argc, char *argv[]) { GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "This is the profiler\n"); cur_test_run.name = "test-rps-profiler"; - num_peers = 100; + num_peers = 16; mal_type = 3; cur_test_run.init_peer = profiler_init_peer; //cur_test_run.pre_test = mal_pre;