aboutsummaryrefslogtreecommitdiff
path: root/src/set/gnunet-service-set_intersection.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2014-11-24 14:06:23 +0000
committerChristian Grothoff <christian@grothoff.org>2014-11-24 14:06:23 +0000
commit30a574dc8b01e16a6b70e384a8c4fe05a6ffd861 (patch)
tree37d16c491c94d3388d2a7d4de959e4c9f591d403 /src/set/gnunet-service-set_intersection.c
parent82f034f771b4fd8e18c61487f4bd239e0e200408 (diff)
downloadgnunet-30a574dc8b01e16a6b70e384a8c4fe05a6ffd861.tar.gz
gnunet-30a574dc8b01e16a6b70e384a8c4fe05a6ffd861.zip
-do not do GC for each destroyed operation on client disconnect
Diffstat (limited to 'src/set/gnunet-service-set_intersection.c')
-rw-r--r--src/set/gnunet-service-set_intersection.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/set/gnunet-service-set_intersection.c b/src/set/gnunet-service-set_intersection.c
index 20fe8682b..606776154 100644
--- a/src/set/gnunet-service-set_intersection.c
+++ b/src/set/gnunet-service-set_intersection.c
@@ -359,7 +359,7 @@ fail_intersection_operation (struct Operation *op)
359 msg->request_id = htonl (op->spec->client_request_id); 359 msg->request_id = htonl (op->spec->client_request_id);
360 msg->element_type = htons (0); 360 msg->element_type = htons (0);
361 GNUNET_MQ_send (op->spec->set->client_mq, ev); 361 GNUNET_MQ_send (op->spec->set->client_mq, ev);
362 _GSS_operation_destroy (op); 362 _GSS_operation_destroy (op, GNUNET_YES);
363} 363}
364 364
365 365
@@ -525,12 +525,13 @@ send_client_done_and_destroy (void *cls)
525 struct Operation *op = cls; 525 struct Operation *op = cls;
526 struct GNUNET_MQ_Envelope *ev; 526 struct GNUNET_MQ_Envelope *ev;
527 struct GNUNET_SET_ResultMessage *rm; 527 struct GNUNET_SET_ResultMessage *rm;
528
528 ev = GNUNET_MQ_msg (rm, GNUNET_MESSAGE_TYPE_SET_RESULT); 529 ev = GNUNET_MQ_msg (rm, GNUNET_MESSAGE_TYPE_SET_RESULT);
529 rm->request_id = htonl (op->spec->client_request_id); 530 rm->request_id = htonl (op->spec->client_request_id);
530 rm->result_status = htons (GNUNET_SET_STATUS_DONE); 531 rm->result_status = htons (GNUNET_SET_STATUS_DONE);
531 rm->element_type = htons (0); 532 rm->element_type = htons (0);
532 GNUNET_MQ_send (op->spec->set->client_mq, ev); 533 GNUNET_MQ_send (op->spec->set->client_mq, ev);
533 _GSS_operation_destroy (op); 534 _GSS_operation_destroy (op, GNUNET_YES);
534} 535}
535 536
536 537
@@ -1050,7 +1051,7 @@ intersection_peer_disconnect (struct Operation *op)
1050 GNUNET_MQ_send (op->spec->set->client_mq, ev); 1051 GNUNET_MQ_send (op->spec->set->client_mq, ev);
1051 GNUNET_log (GNUNET_ERROR_TYPE_WARNING, 1052 GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
1052 "other peer disconnected prematurely\n"); 1053 "other peer disconnected prematurely\n");
1053 _GSS_operation_destroy (op); 1054 _GSS_operation_destroy (op, GNUNET_YES);
1054 return; 1055 return;
1055 } 1056 }
1056 // else: the session has already been concluded 1057 // else: the session has already been concluded