diff --git a/ChangeLog b/ChangeLog index 189c5704..2b235663 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +Thu Dec 4 00:43:10 CET 2014 + If "Connection: upgrade" is requested, do not add + "Connection: Keep-Alive" in the response. -GJ + Tue Nov 18 13:52:29 CET 2014 Call MHD_cleanup_connections() during MHD_DAEMON_INFO_CURRENT_CONNECTIONS processing for more accurate results. -MS diff --git a/src/include/microhttpd.h b/src/include/microhttpd.h index 1de8a0c5..ae0f5031 100644 --- a/src/include/microhttpd.h +++ b/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 0x00093801 +#define MHD_VERSION 0x00093802 /** * MHD-internal return code for "YES". diff --git a/src/microhttpd/connection.c b/src/microhttpd/connection.c index 0515e1fb..72141443 100644 --- a/src/microhttpd/connection.c +++ b/src/microhttpd/connection.c @@ -524,9 +524,10 @@ keepalive_possible (struct MHD_Connection *connection) { if (NULL == end) return MHD_YES; - if (0 == strcasecmp (end, "close")) + if ( (0 == strcasecmp (end, "close")) || + (0 == strcasecmp (end, "upgrade")) ) return MHD_NO; - return MHD_YES; + return MHD_YES; } if (0 == strcasecmp (connection->version, MHD_HTTP_VERSION_1_0))