[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [libmicrohttpd] branch master updated: Improved thread-safe
From: |
gnunet |
Subject: |
[GNUnet-SVN] [libmicrohttpd] branch master updated: Improved thread-safety with suspended connections. |
Date: |
Wed, 15 Mar 2017 19:35:31 +0100 |
This is an automated email from the git hooks/post-receive script.
karlson2k pushed a commit to branch master
in repository libmicrohttpd.
The following commit(s) were added to refs/heads/master by this push:
new afb221c3 Improved thread-safety with suspended connections.
afb221c3 is described below
commit afb221c32aeeb2731e3b5362cc4ff8949d34edea
Author: Evgeny Grin (Karlson2k) <address@hidden>
AuthorDate: Wed Mar 15 21:34:59 2017 +0300
Improved thread-safety with suspended connections.
---
src/microhttpd/connection.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/src/microhttpd/connection.c b/src/microhttpd/connection.c
index 0d55fb3c..40182c4e 100644
--- a/src/microhttpd/connection.c
+++ b/src/microhttpd/connection.c
@@ -2404,7 +2404,8 @@ int
MHD_connection_handle_read (struct MHD_Connection *connection)
{
update_last_activity (connection);
- if (MHD_CONNECTION_CLOSED == connection->state)
+ if ( (MHD_CONNECTION_CLOSED == connection->state) ||
+ (connection->suspended) )
return MHD_YES;
/* make sure "read" has a reasonable number of bytes
in buffer to use per system call (if possible) */
@@ -2474,6 +2475,8 @@ MHD_connection_handle_write (struct MHD_Connection
*connection)
{
struct MHD_Response *response;
ssize_t ret;
+ if (connection->suspended)
+ return MHD_YES;
update_last_activity (connection);
while (1)
--
To stop receiving notification emails like this one, please contact
address@hidden
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] [libmicrohttpd] branch master updated: Improved thread-safety with suspended connections.,
gnunet <=