From: Christian Grothoff Date: Fri, 24 Feb 2017 13:12:03 +0000 (+0100) Subject: permit NULL head X-Git-Tag: taler-0.2.1~70^2~7 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=27d00c1ba73232c8130fdf135a29d0e2551a0023;p=oweals%2Fgnunet.git permit NULL head --- diff --git a/src/cadet/gnunet-service-cadet-new_tunnels.c b/src/cadet/gnunet-service-cadet-new_tunnels.c index 05a1e071d..9d87f9e03 100644 --- a/src/cadet/gnunet-service-cadet-new_tunnels.c +++ b/src/cadet/gnunet-service-cadet-new_tunnels.c @@ -603,8 +603,11 @@ GCT_count_any_connections (const struct CadetTunnel *t) static struct CadetTConnection * get_ready_connection (struct CadetTunnel *t) { - GNUNET_assert (GNUNET_YES == t->connection_ready_head->is_ready); - return t->connection_ready_head; + struct CadetTConnection *hd = t->connection_ready_head; + + GNUNET_assert ( (NULL == hd) || + (GNUNET_YES == hd->is_ready) ); + return hd; }