From 0d2ff615ee0b84852e80d96d5373ebead4c3e423 Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Wed, 22 Feb 2017 13:46:57 +0100 Subject: fix test_dht_montior abortion, fix crash on NULL HELLO --- src/dht/gnunet-service-dht_neighbours.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/dht/gnunet-service-dht_neighbours.c') diff --git a/src/dht/gnunet-service-dht_neighbours.c b/src/dht/gnunet-service-dht_neighbours.c index 9e1cecfcd..810e6196a 100644 --- a/src/dht/gnunet-service-dht_neighbours.c +++ b/src/dht/gnunet-service-dht_neighbours.c @@ -1915,7 +1915,6 @@ handle_find_peer (const struct GNUNET_PeerIdentity *sender, if (NULL == peer) peer = bucket->head; hello = GDS_HELLO_get (peer->id); - hello_size = GNUNET_HELLO_size (hello); } while ( (NULL == hello) || (GNUNET_BLOCK_EVALUATION_OK_MORE != GNUNET_BLOCK_evaluate (GDS_block_context, @@ -1925,7 +1924,7 @@ handle_find_peer (const struct GNUNET_PeerIdentity *sender, &peer->phash, NULL, 0, hello, - hello_size)) ); + (hello_size = GNUNET_HELLO_size (hello)))) ); GDS_NEIGHBOURS_handle_reply (sender, GNUNET_BLOCK_TYPE_DHT_HELLO, GNUNET_TIME_relative_to_absolute -- cgit v1.2.3