aboutsummaryrefslogtreecommitdiff
path: root/src/rps/gnunet-service-rps_custommap.c
diff options
context:
space:
mode:
authorElias Summermatter <elias.summermatter@seccom.ch>2021-03-31 11:17:24 +0200
committerElias Summermatter <elias.summermatter@seccom.ch>2021-03-31 11:17:24 +0200
commit26d2c0d58612fb233cc25b2739bcf96693f5cd85 (patch)
tree16baec844f4a5d9b5383d91589fe4c8f74eec725 /src/rps/gnunet-service-rps_custommap.c
parentb5660e0a33f4c7a819de0b5056172f78f912e352 (diff)
parentca4c9eae269c34765df26699fe756860c7827693 (diff)
downloadgnunet-26d2c0d58612fb233cc25b2739bcf96693f5cd85.tar.gz
gnunet-26d2c0d58612fb233cc25b2739bcf96693f5cd85.zip
Merge branch 'master' of ssh://gnunet.org/gnunet
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;