aboutsummaryrefslogtreecommitdiff
path: root/src/rps/gnunet-service-rps_custommap.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/rps/gnunet-service-rps_custommap.c')
-rw-r--r--src/rps/gnunet-service-rps_custommap.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/rps/gnunet-service-rps_custommap.c b/src/rps/gnunet-service-rps_custommap.c
index 54e361d32..392c29397 100644
--- a/src/rps/gnunet-service-rps_custommap.c
+++ b/src/rps/gnunet-service-rps_custommap.c
@@ -206,6 +206,7 @@ CustomPeerMap_remove_peer (const struct CustomPeerMap *c_peer_map,
206 struct GNUNET_PeerIdentity *p; 206 struct GNUNET_PeerIdentity *p;
207 uint32_t *last_index; 207 uint32_t *last_index;
208 struct GNUNET_PeerIdentity *last_p; 208 struct GNUNET_PeerIdentity *last_p;
209 int ret;
209 210
210 if (GNUNET_NO == CustomPeerMap_contains_peer (c_peer_map, 211 if (GNUNET_NO == CustomPeerMap_contains_peer (c_peer_map,
211 peer)) 212 peer))
@@ -234,9 +235,11 @@ CustomPeerMap_remove_peer (const struct CustomPeerMap *c_peer_map,
234 last_p); 235 last_p);
235 GNUNET_assert (NULL != last_index); 236 GNUNET_assert (NULL != last_index);
236 GNUNET_assert (CustomPeerMap_size (c_peer_map) == *last_index); 237 GNUNET_assert (CustomPeerMap_size (c_peer_map) == *last_index);
237 GNUNET_CONTAINER_multihashmap32_put (c_peer_map->hash_map, 238 ret = GNUNET_CONTAINER_multihashmap32_put (c_peer_map->hash_map,
238 *index, last_p, 239 *index,
239 GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_ONLY); 240 last_p,
241 GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_ONLY);
242 GNUNET_assert (GNUNET_OK == ret);
240 GNUNET_CONTAINER_multihashmap32_remove_all (c_peer_map->hash_map, 243 GNUNET_CONTAINER_multihashmap32_remove_all (c_peer_map->hash_map,
241 *last_index); 244 *last_index);
242 *last_index = *index; 245 *last_index = *index;