aboutsummaryrefslogtreecommitdiff
path: root/src/mesh
diff options
context:
space:
mode:
authorBart Polot <bart@net.in.tum.de>2011-11-04 13:58:18 +0000
committerBart Polot <bart@net.in.tum.de>2011-11-04 13:58:18 +0000
commit892c5652b368111d42ac15d383109bf7212d70ed (patch)
tree1216d5a4537e856ad0103f753b2b05afc16e844d /src/mesh
parent86c37c4c7ffeee1b2c72b1a853d05b3ca84f27b3 (diff)
downloadgnunet-892c5652b368111d42ac15d383109bf7212d70ed.tar.gz
gnunet-892c5652b368111d42ac15d383109bf7212d70ed.zip
Fix for #1871
Diffstat (limited to 'src/mesh')
-rw-r--r--src/mesh/gnunet-service-mesh.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesh/gnunet-service-mesh.c b/src/mesh/gnunet-service-mesh.c
index ad9e42c3c..c0a7852e0 100644
--- a/src/mesh/gnunet-service-mesh.c
+++ b/src/mesh/gnunet-service-mesh.c
@@ -1544,6 +1544,7 @@ peer_info_add_path (struct MeshPeerInfo *peer_info,
1544 path_destroy (path); 1544 path_destroy (path);
1545 return; 1545 return;
1546 } 1546 }
1547 GNUNET_assert (peer_info->id == path->peers[path->length - 1]);
1547 for (l = 1; l < path->length; l++) 1548 for (l = 1; l < path->length; l++)
1548 { 1549 {
1549 if (path->peers[l] == myid) 1550 if (path->peers[l] == myid)
@@ -1556,7 +1557,7 @@ peer_info_add_path (struct MeshPeerInfo *peer_info,
1556 path->peers[l2] = path->peers[l + l2]; 1557 path->peers[l2] = path->peers[l + l2];
1557 } 1558 }
1558 path->length -= l; 1559 path->length -= l;
1559 l = 0; 1560 l = 1;
1560 path->peers = GNUNET_realloc (path->peers, 1561 path->peers = GNUNET_realloc (path->peers,
1561 path->length * sizeof (GNUNET_PEER_Id)); 1562 path->length * sizeof (GNUNET_PEER_Id));
1562 } 1563 }