- cancel maintenance message if connection is confirmed while a maintenance message...
authorBart Polot <bart@net.in.tum.de>
Wed, 26 Oct 2016 04:20:46 +0000 (04:20 +0000)
committerBart Polot <bart@net.in.tum.de>
Wed, 26 Oct 2016 04:20:46 +0000 (04:20 +0000)
src/cadet/gnunet-service-cadet_connection.c

index 6dbabb5ab8ffff93b04cb64a64aaa9e72e9b60ee..da0d6e20daa15b8b888357efd1c7fbf9969a1dbd 100644 (file)
@@ -1583,6 +1583,11 @@ connection_reset_timeout (struct CadetConnection *c, int fwd)
   if (GCC_is_origin (c, fwd)) /* Startpoint */
   {
     schedule_next_keepalive (c, fwd);
+    if (NULL != c->maintenance_q)
+    {
+      GCP_send_cancel (c->maintenance_q);
+      c->maintenance_q = NULL; /* Is set to NULL by conn_message_sent anyway */
+    }
   }
   else /* Relay, endpoint. */
   {