Christian Grothoff 10 лет назад
Родитель
Сommit
5f57331ea1
4 измененных файлов с 18 добавлено и 5 удалено
  1. 9 0
      ChangeLog
  2. 2 2
      configure.ac
  3. 2 2
      src/include/microhttpd.h
  4. 5 1
      src/microhttpd/connection.c

+ 9 - 0
ChangeLog

@@ -1,3 +1,12 @@
+Tue Nov  3 23:24:52 CET 2015
+	Undoing change from Sun Oct 25 15:29:23 CET 2015
+	as the original code was counter-intuitive but
+	correct, and the new code does break pipelining. -CG
+	Releasing libmicrohttpd 0.9.45. -CG
+
+Sat Oct 31 15:52:52 CET 2015
+	Releasing libmicrohttpd 0.9.45. -CG
+
 Tue Oct 27 12:08:02 CET 2015
 	Rework deprecation maros: fix errors with old GCC versions,
 	improved support for old clang and new GCC. -EG

+ 2 - 2
configure.ac

@@ -22,13 +22,13 @@
 #
 AC_PREREQ([2.60])
 LT_PREREQ([2.4.0])
-AC_INIT([libmicrohttpd],[0.9.44],[[email protected]])
+AC_INIT([libmicrohttpd],[0.9.46],[[email protected]])
 AM_INIT_AUTOMAKE([silent-rules] [subdir-objects])
 AC_CONFIG_HEADERS([MHD_config.h])
 AC_CONFIG_MACRO_DIR([m4])
 AH_TOP([#define _GNU_SOURCE  1])
 
-LIB_VERSION_CURRENT=44
+LIB_VERSION_CURRENT=46
 LIB_VERSION_REVISION=0
 LIB_VERSION_AGE=34
 AC_SUBST(LIB_VERSION_CURRENT)

+ 2 - 2
src/include/microhttpd.h

@@ -130,7 +130,7 @@ typedef intptr_t ssize_t;
  * Current version of the library.
  * 0x01093001 = 1.9.30-1.
  */
-#define MHD_VERSION 0x00094403
+#define MHD_VERSION 0x00094600
 
 /**
  * MHD-internal return code for "YES".
@@ -2145,7 +2145,7 @@ MHD_create_response_from_fd_at_offset (size_t size,
                                        int fd,
                                        off_t offset);
 
-#ifndef _MHD_NO_DEPR_IN_MACRO 
+#ifndef _MHD_NO_DEPR_IN_MACRO
 /* Substitute MHD_create_response_from_fd_at_offset64() instead of MHD_create_response_from_fd_at_offset()
    to minimize possible problems with different off_t options */
 #define MHD_create_response_from_fd_at_offset(size,fd,offset) \

+ 5 - 1
src/microhttpd/connection.c

@@ -2555,10 +2555,14 @@ MHD_connection_handle_idle (struct MHD_Connection *connection)
               /* can try to keep-alive */
               connection->version = NULL;
               connection->state = MHD_CONNECTION_INIT;
+              /* read_buffer_size is correct here, as we want to
+                 preserve the entire read buffer allocation, even
+                 if in terms of the data we only care to preserve
+                 up to "read_buffer_offset" */
               connection->read_buffer
                 = MHD_pool_reset (connection->pool,
                                   connection->read_buffer,
-                                  connection->read_buffer_offset);
+                                  connection->read_buffer_size);
             }
 	  connection->client_aware = MHD_NO;
           connection->client_context = NULL;