-fix crash observed on FreeBSD
[oweals/gnunet.git] / src / conversation / conversation_api_call.c
index 16173a4fbe44d9487a62e241c0c9901841b903c9..f69a6518cfc2fd997e688605094d6ecfed3d1672 100644 (file)
@@ -384,7 +384,7 @@ handle_call_audio_message (void *cls,
     break;
   case CS_SUSPENDED_CALLEE:
   case CS_SUSPENDED_BOTH:
-    /* can (rarely) also happen: other peer suspended, but mesh might
+    /* can (rarely) also happen: other peer suspended, but cadet might
        have had delayed data on the unreliable channel */
     break;
   case CS_ACTIVE:
@@ -417,7 +417,7 @@ handle_gns_response (void *cls,
   struct ClientCallMessage *ccm;
 
   GNUNET_break (NULL != call->gns_lookup);
-  GNUNET_break (CS_LOOKUP == call->gns_lookup);
+  GNUNET_break (CS_LOOKUP == call->state);
   call->gns_lookup = NULL;
   for (i=0;i<rd_count;i++)
   {
@@ -518,10 +518,13 @@ reconnect_call (struct GNUNET_CONVERSATION_Call *call)
   }
   call->state = CS_SHUTDOWN;
   call->client = GNUNET_CLIENT_connect ("conversation", call->cfg);
-  if (NULL == call->client);
-    return;
-  call->event_handler (call->event_handler_cls,
+  if (NULL == call->client)
+  {
+    call->event_handler (call->event_handler_cls,
                        GNUNET_CONVERSATION_EC_CALL_ERROR);
+    return;
+  }
+
   call->mq = GNUNET_MQ_queue_for_connection_client (call->client,
                                                     handlers,
                                                     &call_error_handler,