From: Nathan S. Evans Date: Mon, 22 Nov 2010 12:29:21 +0000 (+0000) Subject: checking if pending_head is NULL, may not be correct X-Git-Tag: initial-import-from-subversion-38251~19664 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=8b2e3426bf1b5ddfd54ce7a123dd17159247472a;p=oweals%2Fgnunet.git checking if pending_head is NULL, may not be correct --- diff --git a/src/core/core_api.c b/src/core/core_api.c index 48de0a214..02c9e43a2 100644 --- a/src/core/core_api.c +++ b/src/core/core_api.c @@ -666,6 +666,12 @@ transmit_message (void *cls, /* now check for 'ready' P2P messages */ if (NULL != (pr = h->ready_peer_head)) { + /* FIXME: If a reconnect_later call happened, this can be NULL! */ + if (pr->pending_head == NULL) + { + GNUNET_break(0); + return 0; + } th = pr->pending_head; if (size < th->msize + sizeof (struct SendMessage)) {