[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r28906 - gnunet/src/mesh
From: |
gnunet |
Subject: |
[GNUnet-SVN] r28906 - gnunet/src/mesh |
Date: |
Fri, 30 Aug 2013 05:53:35 +0200 |
Author: bartpolot
Date: 2013-08-30 05:53:34 +0200 (Fri, 30 Aug 2013)
New Revision: 28906
Modified:
gnunet/src/mesh/gnunet-service-mesh-enc.c
Log:
- remove channels from client hashmap on disconnect
Modified: gnunet/src/mesh/gnunet-service-mesh-enc.c
===================================================================
--- gnunet/src/mesh/gnunet-service-mesh-enc.c 2013-08-30 03:43:00 UTC (rev
28905)
+++ gnunet/src/mesh/gnunet-service-mesh-enc.c 2013-08-30 03:53:34 UTC (rev
28906)
@@ -1840,6 +1840,7 @@
struct GNUNET_MESH_Encrypted *emsg;
struct GNUNET_MESH_ACK *amsg;
struct GNUNET_MESH_Poll *pmsg;
+ struct GNUNET_MESH_ConnectionDestroy *dmsg;
uint32_t ttl;
case GNUNET_MESSAGE_TYPE_MESH_FWD:
@@ -1870,6 +1871,12 @@
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, " poll %u\n", ntohl (pmsg->pid));
break;
+ case GNUNET_MESSAGE_TYPE_MESH_TUNNEL_DESTROY:
+ dmsg = (struct GNUNET_MESH_ConnectionDestroy *) data;
+ dmsg->cid = c->id;
+ dmsg->reserved = 0;
+ break;
+
default:
GNUNET_break (0);
}
@@ -4156,7 +4163,7 @@
if (channel_is_terminal (ch, GNUNET_NO))
{
- if (NULL != ch->root)
+ if (NULL != ch->root && GNUNET_NO == ch->root->shutting_down)
{
msg.chid = htonl (ch->lid_root);
send_local_channel_destroy (ch, GNUNET_NO);
@@ -4170,7 +4177,7 @@
if (channel_is_terminal (ch, GNUNET_YES))
{
- if (NULL != ch->dest)
+ if (NULL != ch->dest && GNUNET_NO == ch->dest->shutting_down)
{
msg.chid = htonl (ch->lid_dest);
send_local_channel_destroy (ch, GNUNET_YES);
@@ -4520,12 +4527,10 @@
if (c == ch->dest)
{
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, " Client %u is destination.\n",
c->id);
- ch->dest = NULL;
}
if (c == ch->root)
{
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, " Client %u is owner.\n", c->id);
- ch->root = NULL;
}
t = ch->t;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r28906 - gnunet/src/mesh,
gnunet <=