diff options
author | Evgeny Grin (Karlson2k) <k2k@narod.ru> | 2016-10-24 21:17:27 +0300 |
---|---|---|
committer | Evgeny Grin (Karlson2k) <k2k@narod.ru> | 2016-10-27 22:45:01 +0300 |
commit | 80d4152e1f287d1572833246dcc3aa676410e9f4 (patch) | |
tree | 27a727f4d58bec7d4eb9365237da121c012e97c5 | |
parent | 5b01262799b1eef4e78b0264f9715fbf7bff1857 (diff) | |
download | libmicrohttpd-80d4152e1f287d1572833246dcc3aa676410e9f4.tar.gz libmicrohttpd-80d4152e1f287d1572833246dcc3aa676410e9f4.zip |
Used smaller locked mutex scope.
-rw-r--r-- | src/microhttpd/daemon.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/microhttpd/daemon.c b/src/microhttpd/daemon.c index 459b82b2..f22c717a 100644 --- a/src/microhttpd/daemon.c +++ b/src/microhttpd/daemon.c | |||
@@ -2422,6 +2422,8 @@ MHD_resume_connection (struct MHD_Connection *connection) | |||
2422 | MHD_mutex_lock_chk_ (&daemon->cleanup_connection_mutex); | 2422 | MHD_mutex_lock_chk_ (&daemon->cleanup_connection_mutex); |
2423 | connection->resuming = MHD_YES; | 2423 | connection->resuming = MHD_YES; |
2424 | daemon->resuming = MHD_YES; | 2424 | daemon->resuming = MHD_YES; |
2425 | if (0 != (daemon->options & MHD_USE_THREAD_PER_CONNECTION)) | ||
2426 | MHD_mutex_unlock_chk_ (&daemon->cleanup_connection_mutex); | ||
2425 | if ( (MHD_ITC_IS_VALID_(daemon->itc)) && | 2427 | if ( (MHD_ITC_IS_VALID_(daemon->itc)) && |
2426 | (! MHD_itc_activate_ (daemon->itc, "r")) ) | 2428 | (! MHD_itc_activate_ (daemon->itc, "r")) ) |
2427 | { | 2429 | { |
@@ -2430,8 +2432,6 @@ MHD_resume_connection (struct MHD_Connection *connection) | |||
2430 | _("Failed to signal resume via inter-thread communication channel.")); | 2432 | _("Failed to signal resume via inter-thread communication channel.")); |
2431 | #endif | 2433 | #endif |
2432 | } | 2434 | } |
2433 | if (0 != (daemon->options & MHD_USE_THREAD_PER_CONNECTION)) | ||
2434 | MHD_mutex_unlock_chk_ (&daemon->cleanup_connection_mutex); | ||
2435 | } | 2435 | } |
2436 | 2436 | ||
2437 | 2437 | ||