commit 777d5e048d02a46c535f6e53fa31cda5c5d09038 parent 533124d379d0c0e3e1efa9a4c9bcccd4e6a8bdba Author: Christian Grothoff <christian@grothoff.org> Date: Mon, 29 Oct 2018 20:37:21 +0100 force setting MHD_USE_ITC if using thread-per-connection and notify_completed for timely notifications Diffstat:
| M | src/microhttpd/daemon.c | | | 8 | +++++++- |
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/src/microhttpd/daemon.c b/src/microhttpd/daemon.c @@ -5531,9 +5531,15 @@ MHD_start_daemon_va (unsigned int flags, free (daemon); return NULL; } + + if ( (NULL != daemon->notify_completed) && + (0 != (daemon->options & MHD_USE_THREAD_PER_CONNECTION)) ) + *pflags |= MHD_USE_ITC; /* requires ITC */ + #ifndef NDEBUG #ifdef HAVE_MESSAGES - MHD_DLOG (daemon, _("Using debug build of libmicrohttpd.\n") ); + MHD_DLOG (daemon, + _("Using debug build of libmicrohttpd.\n") ); #endif /* HAVE_MESSAGES */ #endif /* ! NDEBUG */