aboutsummaryrefslogtreecommitdiff
path: root/src/set/gnunet-service-set.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2015-10-08 11:30:19 +0000
committerChristian Grothoff <christian@grothoff.org>2015-10-08 11:30:19 +0000
commitae53a8d1d043cbd5967fb01316a32685c7a8af9b (patch)
treea8d791aed993ac8691f68ee6152a6ffb14a88ee3 /src/set/gnunet-service-set.c
parente105a542a8ddb22184712bfe565aa734f1d0349d (diff)
downloadgnunet-ae53a8d1d043cbd5967fb01316a32685c7a8af9b.tar.gz
gnunet-ae53a8d1d043cbd5967fb01316a32685c7a8af9b.zip
add logic for strata compression
Diffstat (limited to 'src/set/gnunet-service-set.c')
-rw-r--r--src/set/gnunet-service-set.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/set/gnunet-service-set.c b/src/set/gnunet-service-set.c
index cfddef6fb..441637a93 100644
--- a/src/set/gnunet-service-set.c
+++ b/src/set/gnunet-service-set.c
@@ -975,7 +975,7 @@ again:
975 GNUNET_CONTAINER_multihashmap_iterator_destroy (set->iter); 975 GNUNET_CONTAINER_multihashmap_iterator_destroy (set->iter);
976 set->iter = NULL; 976 set->iter = NULL;
977 set->iteration_id++; 977 set->iteration_id++;
978 978
979 GNUNET_assert (set->content->iterator_count > 0); 979 GNUNET_assert (set->content->iterator_count > 0);
980 set->content->iterator_count -= 1; 980 set->content->iterator_count -= 1;
981 981
@@ -1113,6 +1113,13 @@ handle_client_create_set (void *cls,
1113 } 1113 }
1114 set->operation = ntohl (msg->operation); 1114 set->operation = ntohl (msg->operation);
1115 set->state = set->vt->create (); 1115 set->state = set->vt->create ();
1116 if (NULL == set->state)
1117 {
1118 /* initialization failed (i.e. out of memory) */
1119 GNUNET_free (set);
1120 GNUNET_SERVER_client_disconnect (client);
1121 return;
1122 }
1116 set->content = GNUNET_new (struct SetContent); 1123 set->content = GNUNET_new (struct SetContent);
1117 set->content->refcount = 1; 1124 set->content->refcount = 1;
1118 set->content->elements = GNUNET_CONTAINER_multihashmap_create (1, GNUNET_YES); 1125 set->content->elements = GNUNET_CONTAINER_multihashmap_create (1, GNUNET_YES);
@@ -1497,7 +1504,7 @@ handle_client_copy_lazy_connect (void *cls,
1497 { 1504 {
1498 found = GNUNET_YES; 1505 found = GNUNET_YES;
1499 break; 1506 break;
1500 } 1507 }
1501 } 1508 }
1502 1509
1503 if (GNUNET_NO == found) 1510 if (GNUNET_NO == found)