fix
authorChristian Grothoff <christian@grothoff.org>
Tue, 2 Aug 2011 14:06:45 +0000 (14:06 +0000)
committerChristian Grothoff <christian@grothoff.org>
Tue, 2 Aug 2011 14:06:45 +0000 (14:06 +0000)
src/transport/test_quota_compliance.c

index a3b135eb224a281fa186eecb960daaaee9b41a6b..921fa954218d4590a26afd00d01e4b936d60afb1 100644 (file)
@@ -615,8 +615,11 @@ notify_connect (void *cls,
     }
   if (connected == 2)
     {
-      GNUNET_SCHEDULER_cancel (tct);
-      tct = GNUNET_SCHEDULER_NO_TASK;
+      if (GNUNET_SCHEDULER_NO_TASK != tct)
+       {
+         GNUNET_SCHEDULER_cancel (tct);
+         tct = GNUNET_SCHEDULER_NO_TASK;
+       }
       GNUNET_TRANSPORT_get_hello_cancel (p2.th, &exchange_hello_last, &p2);
       GNUNET_TRANSPORT_get_hello_cancel (p1.th, &exchange_hello, &p1);
       if (is_asymmetric_send_constant == GNUNET_YES)