gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] r29874 - gnunet/src/conversation


From: gnunet
Subject: [GNUnet-SVN] r29874 - gnunet/src/conversation
Date: Sat, 5 Oct 2013 20:49:56 +0200

Author: grothoff
Date: 2013-10-05 20:49:55 +0200 (Sat, 05 Oct 2013)
New Revision: 29874

Modified:
   gnunet/src/conversation/gnunet-service-conversation.c
Log:
-update to reflect mesh API change

Modified: gnunet/src/conversation/gnunet-service-conversation.c
===================================================================
--- gnunet/src/conversation/gnunet-service-conversation.c       2013-10-05 
18:49:24 UTC (rev 29873)
+++ gnunet/src/conversation/gnunet-service-conversation.c       2013-10-05 
18:49:55 UTC (rev 29874)
@@ -976,12 +976,19 @@
   size_t msize = ntohs (message->size) - sizeof (struct MeshAudioMessage);
   char buf[msize + sizeof (struct ClientAudioMessage)];
   struct ClientAudioMessage *cam;
+  const union GNUNET_MESH_TunnelInfo *info;
   
   msg = (const struct MeshAudioMessage *) message;
   if (NULL == line)
   {
-    sender = *GNUNET_MESH_tunnel_get_info (tunnel,
-                                           GNUNET_MESH_OPTION_PEER)->peer;
+    info = GNUNET_MESH_tunnel_get_info (tunnel,
+                                        GNUNET_MESH_OPTION_PEER);
+    if (NULL == info)
+    {
+      GNUNET_break (0);
+      return GNUNET_OK;
+    }
+    sender = info->peer;
     for (line = lines_head; NULL != line; line = line->next)
       if ( (line->local_line == ntohl (msg->remote_line)) &&
            (LS_CALLEE_CONNECTED == line->status) &&
@@ -996,7 +1003,7 @@
                   "Received AUDIO data for non-existing line %u, dropping.\n",
                   ntohl (msg->remote_line));
       return GNUNET_SYSERR;
-    }
+    }    
     line->tunnel_unreliable = tunnel;
     *tunnel_ctx = line;
   }
@@ -1063,7 +1070,8 @@
     line->tunnel_unreliable = NULL;
     return;
   }
-  GNUNET_assert (line->tunnel_reliable == tunnel);
+  if (line->tunnel_reliable != tunnel)
+    return;
   line->tunnel_reliable = NULL;
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
              "Mesh tunnel destroyed by mesh\n");




reply via email to

[Prev in Thread] Current Thread [Next in Thread]