diff options
author | Christian Grothoff <christian@grothoff.org> | 2011-09-19 12:06:46 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2011-09-19 12:06:46 +0000 |
commit | 211920f3ef774ab6009814d40caca9358881ba34 (patch) | |
tree | 7153f30f0c28d46af8378a99c5fae5e5671e1b9c | |
parent | e9cf773a0ae6367ea21eb9d98a01e4a4088ce0e5 (diff) | |
download | libmicrohttpd-211920f3ef774ab6009814d40caca9358881ba34.tar.gz libmicrohttpd-211920f3ef774ab6009814d40caca9358881ba34.zip |
trying to fix Regis's problem
-rw-r--r-- | ChangeLog | 3 | ||||
-rw-r--r-- | src/daemon/connection.c | 10 |
2 files changed, 8 insertions, 5 deletions
@@ -1,3 +1,6 @@ | |||
1 | Mon Sep 19 14:06:30 CEST 2011 | ||
2 | Fixing problem introduced with prompt response cleanup code. -CG | ||
3 | |||
1 | Wed Sep 14 13:43:26 CEST 2011 | 4 | Wed Sep 14 13:43:26 CEST 2011 |
2 | Fixing minor memory leak if daemon with HTTPS support failed to | 5 | Fixing minor memory leak if daemon with HTTPS support failed to |
3 | initialize (#1766). -CG | 6 | initialize (#1766). -CG |
diff --git a/src/daemon/connection.c b/src/daemon/connection.c index 1b95379c..00188a84 100644 --- a/src/daemon/connection.c +++ b/src/daemon/connection.c | |||
@@ -311,11 +311,6 @@ MHD_connection_close (struct MHD_Connection *connection, | |||
311 | &connection->client_context, | 311 | &connection->client_context, |
312 | termination_code); | 312 | termination_code); |
313 | connection->client_aware = MHD_NO; | 313 | connection->client_aware = MHD_NO; |
314 | if (connection->response != NULL) | ||
315 | { | ||
316 | MHD_destroy_response (connection->response); | ||
317 | connection->response = NULL; | ||
318 | } | ||
319 | } | 314 | } |
320 | 315 | ||
321 | 316 | ||
@@ -2291,6 +2286,11 @@ MHD_connection_handle_idle (struct MHD_Connection *connection) | |||
2291 | } | 2286 | } |
2292 | continue; | 2287 | continue; |
2293 | case MHD_CONNECTION_CLOSED: | 2288 | case MHD_CONNECTION_CLOSED: |
2289 | if (connection->response != NULL) | ||
2290 | { | ||
2291 | MHD_destroy_response (connection->response); | ||
2292 | connection->response = NULL; | ||
2293 | } | ||
2294 | daemon = connection->daemon; | 2294 | daemon = connection->daemon; |
2295 | if (0 != pthread_mutex_lock(&daemon->cleanup_connection_mutex)) | 2295 | if (0 != pthread_mutex_lock(&daemon->cleanup_connection_mutex)) |
2296 | { | 2296 | { |