diff options
author | Christian Grothoff <christian@grothoff.org> | 2012-06-24 07:31:11 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2012-06-24 07:31:11 +0000 |
commit | 6646a17fc129acf1c2d397492f2ca9cda4b4b8b4 (patch) | |
tree | 7c81d3bc32efb0051a3e6174af764c55a6c0254e /src/stream | |
parent | 13e4cac761ebcfb57ab7d0af4f3116e585e560b9 (diff) | |
download | gnunet-6646a17fc129acf1c2d397492f2ca9cda4b4b8b4.tar.gz gnunet-6646a17fc129acf1c2d397492f2ca9cda4b4b8b4.zip |
-LRN: Don't free shutdown handle while it's in use
Diffstat (limited to 'src/stream')
-rw-r--r-- | src/stream/stream_api.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/stream/stream_api.c b/src/stream/stream_api.c index 18435d0a7..df0710e80 100644 --- a/src/stream/stream_api.c +++ b/src/stream/stream_api.c | |||
@@ -1741,8 +1741,6 @@ handle_generic_close_ack (struct GNUNET_STREAM_Socket *socket, | |||
1741 | if (NULL != shutdown_handle->completion_cb) /* Shutdown completion */ | 1741 | if (NULL != shutdown_handle->completion_cb) /* Shutdown completion */ |
1742 | shutdown_handle->completion_cb(shutdown_handle->completion_cls, | 1742 | shutdown_handle->completion_cb(shutdown_handle->completion_cls, |
1743 | operation); | 1743 | operation); |
1744 | GNUNET_free (shutdown_handle); /* Free shutdown handle */ | ||
1745 | socket->shutdown_handle = NULL; | ||
1746 | if (GNUNET_SCHEDULER_NO_TASK | 1744 | if (GNUNET_SCHEDULER_NO_TASK |
1747 | != shutdown_handle->close_msg_retransmission_task_id) | 1745 | != shutdown_handle->close_msg_retransmission_task_id) |
1748 | { | 1746 | { |
@@ -1751,6 +1749,8 @@ handle_generic_close_ack (struct GNUNET_STREAM_Socket *socket, | |||
1751 | shutdown_handle->close_msg_retransmission_task_id = | 1749 | shutdown_handle->close_msg_retransmission_task_id = |
1752 | GNUNET_SCHEDULER_NO_TASK; | 1750 | GNUNET_SCHEDULER_NO_TASK; |
1753 | } | 1751 | } |
1752 | GNUNET_free (shutdown_handle); /* Free shutdown handle */ | ||
1753 | socket->shutdown_handle = NULL; | ||
1754 | return GNUNET_OK; | 1754 | return GNUNET_OK; |
1755 | } | 1755 | } |
1756 | 1756 | ||