From 6fd34d4e09d94710855d4a712474ed51f3ffdb6f Mon Sep 17 00:00:00 2001 From: Bart Polot Date: Mon, 24 Oct 2011 14:33:30 +0000 Subject: Don't die on unknown peer --- src/mesh/test_mesh_small.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'src/mesh') diff --git a/src/mesh/test_mesh_small.c b/src/mesh/test_mesh_small.c index e77ddcf15..9f075638a 100644 --- a/src/mesh/test_mesh_small.c +++ b/src/mesh/test_mesh_small.c @@ -524,7 +524,6 @@ topo_cb (void *cls, GNUNET_log (GNUNET_ERROR_TYPE_WARNING, "***************** test: %s is UNKNOWN!?\n", GNUNET_i2s(second)); - GNUNET_break (0); return; } mesh_peers[p2]++; @@ -538,7 +537,13 @@ topo_cb (void *cls, { p2 = GNUNET_PEER_search(first); GNUNET_assert(p2 < num_peers); - GNUNET_assert(p2 > 0); + if (p2 == 0) + { + GNUNET_log (GNUNET_ERROR_TYPE_WARNING, + "***************** test: %s is UNKNOWN!?\n", + GNUNET_i2s(second)); + return; + } mesh_peers[p2]++; GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "***************** test: %s IS a neighbor\n", -- cgit v1.2.3