gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] [libmicrohttpd] branch master updated: Do not fail on overf


From: gnunet
Subject: [GNUnet-SVN] [libmicrohttpd] branch master updated: Do not fail on overflown read buffer while connection is suspended.
Date: Fri, 17 Mar 2017 08:53:06 +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 9fec9b35 Do not fail on overflown read buffer while connection is 
suspended.
9fec9b35 is described below

commit 9fec9b35ec46ce51cdda1f7e264f48b9f02f2f4d
Author: Evgeny Grin (Karlson2k) <address@hidden>
AuthorDate: Fri Mar 17 10:52:38 2017 +0300

    Do not fail on overflown read buffer while connection is suspended.
---
 ChangeLog                   | 7 +++++++
 src/microhttpd/connection.c | 5 ++++-
 2 files changed, 11 insertions(+), 1 deletion(-)

diff --git a/ChangeLog b/ChangeLog
index 961a1585..75bd5ff9 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+Thu Mar 17 10:45:31 MSK 2017
+       If read buffer is full, MHD need to receive remote data and application
+       suspended connection, do not fail while connection is suspended and give
+       application one more chance to read data from buffer once connection is
+       resumed. -EG
+
 Thu Mar 16 23:45:29 MSK 2017
        Allow again to run MHD in external epoll mode by
        MHD_run_from_select() - this allow unification of user code
@@ -15,6 +21,7 @@ Thu Mar 16 22:31:54 MSK 2017
        Removed early duplicated check for timeout on HTTPS connections.
        Removed update of last active time for connections without timeout.
        Fixed reset of timeout timer on resumed connections.
+       Fixed never-expired timeouts on HTTPS connections.
        Fixed thread-safety of MHD_set_connection_option(). -EG
 
 Thu Mar 16 21:05:08 MSK 2017
diff --git a/src/microhttpd/connection.c b/src/microhttpd/connection.c
index 2b1c35da..92194ac6 100644
--- a/src/microhttpd/connection.c
+++ b/src/microhttpd/connection.c
@@ -1410,7 +1410,8 @@ MHD_connection_update_event_loop_info (struct 
MHD_Connection *connection)
             {
               if ((MHD_YES != try_grow_read_buffer (connection)) &&
                   (0 != (connection->daemon->options &
-                         MHD_USE_INTERNAL_POLLING_THREAD)))
+                         MHD_USE_INTERNAL_POLLING_THREAD)) &&
+                  (! connection->suspended))
                 {
                   /* failed to grow the read buffer, and the
                      client which is supposed to handle the
@@ -1423,6 +1424,8 @@ MHD_connection_update_event_loop_info (struct 
MHD_Connection *connection)
                      on the connection (if a timeout is even
                      set!).
                      Solution: we kill the connection with an error */
+                  /* If connection is suspended, give application one
+                   * more chance to read data once connection is resumed. */
                   transmit_error_response (connection,
                                            MHD_HTTP_INTERNAL_SERVER_ERROR,
                                            INTERNAL_ERROR);

-- 
To stop receiving notification emails like this one, please contact
address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]