summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBart Polot <bart@net.in.tum.de>2011-11-12 01:01:33 +0000
committerBart Polot <bart@net.in.tum.de>2011-11-12 01:01:33 +0000
commit10e15b413ce8aa828dc49040c9e545c07edee86b (patch)
treee112ee9fb2d712d4c8c90b7d478bc5ec4fd9653a /src
parent14c3c77ea2bbac38dc30e1505600d1a41a1c7605 (diff)
Fixed issue related to mantis #1896, when a path ack of an already connected peer would cause client notification about new peer
Diffstat (limited to 'src')
-rw-r--r--src/mesh/gnunet-service-mesh.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/mesh/gnunet-service-mesh.c b/src/mesh/gnunet-service-mesh.c
index ef1ba1f8a..14dd5d1fd 100644
--- a/src/mesh/gnunet-service-mesh.c
+++ b/src/mesh/gnunet-service-mesh.c
@@ -3074,8 +3074,11 @@ handle_mesh_path_ack (void *cls, const struct GNUNET_PeerIdentity *peer,
t->dht_get_type = NULL;
}
peer_info = peer_info_get (&msg->peer_id);
- tree_set_status (t->tree, peer_info->id, MESH_PEER_READY);
- send_client_peer_connected (t, peer_info->id);
+ if (tree_get_status(t->tree, peer_info->id) != MESH_PEER_READY)
+ {
+ tree_set_status (t->tree, peer_info->id, MESH_PEER_READY);
+ send_client_peer_connected (t, peer_info->id);
+ }
return GNUNET_OK;
}