diff options
author | Christian Grothoff <christian@grothoff.org> | 2014-11-30 16:53:11 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2014-11-30 16:53:11 +0000 |
commit | 6e92863ee3b53577d31f4a0e3bf5bad8e47f4437 (patch) | |
tree | 1f47c5b50299fc4ddddc474cb091b8dc196480b1 /src/set/gnunet-service-set.c | |
parent | 3ff74fa1dac7f7b839930959962f4f1c843708bd (diff) | |
download | gnunet-6e92863ee3b53577d31f4a0e3bf5bad8e47f4437.tar.gz gnunet-6e92863ee3b53577d31f4a0e3bf5bad8e47f4437.zip |
-use keep as RC to address #3561
Diffstat (limited to 'src/set/gnunet-service-set.c')
-rw-r--r-- | src/set/gnunet-service-set.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/set/gnunet-service-set.c b/src/set/gnunet-service-set.c index c40ac9c53..746a9da02 100644 --- a/src/set/gnunet-service-set.c +++ b/src/set/gnunet-service-set.c | |||
@@ -1388,6 +1388,7 @@ channel_end_cb (void *cls, | |||
1388 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1388 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1389 | "channel_end_cb called\n"); | 1389 | "channel_end_cb called\n"); |
1390 | op->channel = NULL; | 1390 | op->channel = NULL; |
1391 | op->keep++; | ||
1391 | /* the vt can be null if a client already requested canceling op. */ | 1392 | /* the vt can be null if a client already requested canceling op. */ |
1392 | if (NULL != op->vt) | 1393 | if (NULL != op->vt) |
1393 | { | 1394 | { |
@@ -1395,7 +1396,8 @@ channel_end_cb (void *cls, | |||
1395 | "calling peer disconnect due to channel end\n"); | 1396 | "calling peer disconnect due to channel end\n"); |
1396 | op->vt->peer_disconnect (op); | 1397 | op->vt->peer_disconnect (op); |
1397 | } | 1398 | } |
1398 | if (GNUNET_YES != op->keep) | 1399 | op->keep--; |
1400 | if (0 == op->keep) | ||
1399 | { | 1401 | { |
1400 | /* cadet will never call us with the context again! */ | 1402 | /* cadet will never call us with the context again! */ |
1401 | GNUNET_free (op); | 1403 | GNUNET_free (op); |