Extending the testcases to use bluetooth
[oweals/gnunet.git] / src / transport / transport_api.c
index ac37274c6bbb90f991df0c6915269ad9d4a85a54..f92895c528b0ad7b043ffacb0f1dd1b531d44e8d 100644 (file)
@@ -1054,10 +1054,10 @@ send_try_connect (void *cls, size_t size, void *buf)
     if (NULL != tch->cb)
       tch->cb (tch->cb_cls, GNUNET_SYSERR);
     GNUNET_CONTAINER_DLL_remove (tch->th->tc_head, tch->th->tc_tail, tch);
-    GNUNET_free (tch);
     LOG (GNUNET_ERROR_TYPE_DEBUG,
          "Discarding  `%s' request to `%4s' due to error in transport service connection.\n", "REQUEST_CONNECT",
          GNUNET_i2s (&tch->pid));
+    GNUNET_free (tch);
     return 0;
   }
   LOG (GNUNET_ERROR_TYPE_DEBUG,