libmicrohttpd

HTTP/1.x server C library (MHD 1.x, stable)
Log | Files | Refs | Submodules | README | LICENSE

commit d5048c22857105d23364a1c783975a040d608143
parent 58b30e7e5e90ff87ef932ea4e47efe16e2609188
Author: Christian Grothoff <christian@grothoff.org>
Date:   Tue,  4 Aug 2015 11:52:05 +0000

fix #3924

Diffstat:
MChangeLog | 6++++++
Msrc/include/microhttpd.h | 2+-
Msrc/microhttpd/daemon.c | 2--
3 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/ChangeLog b/ChangeLog @@ -1,3 +1,9 @@ +Tue Aug 4 13:50:23 CEST 2015 + Fix failure to properly clean up timed out connections + if running in external select mode without listen socket, + which caused busy waiting until new connections arrived. + (Fixes #3924, thanks to slimp for reporting and testcase). -CG + Sun Aug 2 19:08:20 CEST 2015 Ignore close() errors on sockets except for EBADF, fixes #3926. -CG diff --git 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 0x00094207 +#define MHD_VERSION 0x00094208 /** * MHD-internal return code for "YES". diff --git a/src/microhttpd/daemon.c b/src/microhttpd/daemon.c @@ -2351,8 +2351,6 @@ MHD_select (struct MHD_Daemon *daemon, timeout.tv_sec = ltimeout / 1000; tv = &timeout; } - if (MHD_INVALID_SOCKET == max) - return MHD_YES; num_ready = MHD_SYS_select_ (max + 1, &rs, &ws, &es, tv); if (MHD_YES == daemon->shutdown) return MHD_NO;