From: Bart Polot Date: Thu, 14 Nov 2013 10:31:02 +0000 (+0000) Subject: - fix NPE X-Git-Tag: initial-import-from-subversion-38251~6123 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=a22a030590120a44e86cbc11e41198969b4f3318;p=oweals%2Fgnunet.git - fix NPE --- diff --git a/src/mesh/gnunet-service-mesh_channel.c b/src/mesh/gnunet-service-mesh_channel.c index c334932d7..de2c465b7 100644 --- a/src/mesh/gnunet-service-mesh_channel.c +++ b/src/mesh/gnunet-service-mesh_channel.c @@ -1292,7 +1292,7 @@ GMCH_allow_client (struct MeshChannel *ch, int fwd) GNUNET_break (0); return; } - if (64 <= rel->mid_send - rel->head_sent->mid) + if (NULL != rel->head_sent && 64 <= rel->mid_send - rel->head_sent->mid) { LOG (GNUNET_ERROR_TYPE_DEBUG, " too big mid gap! Wait for ACK.\n");