aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/mesh/gnunet-service-mesh.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mesh/gnunet-service-mesh.c b/src/mesh/gnunet-service-mesh.c
index 7ecff0a839..85292f8f63 100644
--- a/src/mesh/gnunet-service-mesh.c
+++ b/src/mesh/gnunet-service-mesh.c
@@ -5846,7 +5846,9 @@ handle_mesh_tunnel_destroy (void *cls, const struct GNUNET_PeerIdentity *peer,
if (pid != parent)
{
tree_del_peer (t->tree, pid, &tunnel_child_removed, t);
- if (tree_count_children(t->tree) > 0 || NULL != t->owner)
+ if (tree_count_children(t->tree) > 0 ||
+ NULL != t->owner ||
+ t->nclients > 0)
return GNUNET_OK;
}
if (t->local_tid_dest >= GNUNET_MESH_LOCAL_TUNNEL_ID_SERV)