diff options
Diffstat (limited to 'src/transport/plugin_transport_udp.c')
-rw-r--r-- | src/transport/plugin_transport_udp.c | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/src/transport/plugin_transport_udp.c b/src/transport/plugin_transport_udp.c index bb3af28dd..d1cfbc620 100644 --- a/src/transport/plugin_transport_udp.c +++ b/src/transport/plugin_transport_udp.c | |||
@@ -1265,14 +1265,17 @@ udp_disconnect_session (void *cls, struct Session *s) | |||
1265 | frc.addr = s->address->address; | 1265 | frc.addr = s->address->address; |
1266 | frc.addr_len = s->address->address_length; | 1266 | frc.addr_len = s->address->address_length; |
1267 | /* Lookup existing receive context for this address */ | 1267 | /* Lookup existing receive context for this address */ |
1268 | GNUNET_CONTAINER_heap_iterate (plugin->defrag_ctxs, | 1268 | if (NULL != plugin->defrag_ctxs) |
1269 | &find_receive_context, &frc); | ||
1270 | if (NULL != frc.rc) | ||
1271 | { | 1269 | { |
1272 | struct DefragContext *d_ctx = frc.rc; | 1270 | GNUNET_CONTAINER_heap_iterate (plugin->defrag_ctxs, |
1273 | GNUNET_CONTAINER_heap_remove_node (d_ctx->hnode); | 1271 | &find_receive_context, &frc); |
1274 | GNUNET_DEFRAGMENT_context_destroy (d_ctx->defrag); | 1272 | if (NULL != frc.rc) |
1275 | GNUNET_free (d_ctx); | 1273 | { |
1274 | struct DefragContext *d_ctx = frc.rc; | ||
1275 | GNUNET_CONTAINER_heap_remove_node (d_ctx->hnode); | ||
1276 | GNUNET_DEFRAGMENT_context_destroy (d_ctx->defrag); | ||
1277 | GNUNET_free (d_ctx); | ||
1278 | } | ||
1276 | } | 1279 | } |
1277 | 1280 | ||
1278 | next = plugin->ipv4_queue_head; | 1281 | next = plugin->ipv4_queue_head; |