libmicrohttpd

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

commit b473e121317ca280e2070914033d9e26f0e7ddab
parent f05715b71f2ca4096f0b90e0e7bbfc3da1137e86
Author: Evgeny Grin (Karlson2k) <k2k@narod.ru>
Date:   Sun, 19 Feb 2017 19:02:43 +0300

call_handlers(): use 'bool' type for parameters

Diffstat:
Msrc/microhttpd/daemon.c | 20++++++++++----------
1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/src/microhttpd/daemon.c b/src/microhttpd/daemon.c @@ -887,9 +887,9 @@ MHD_get_fdset2 (struct MHD_Daemon *daemon, */ static int call_handlers (struct MHD_Connection *con, - int read_ready, - int write_ready, - int force_close) + bool read_ready, + bool write_ready, + bool force_close) { int ret; /* Initial state of connection. */ @@ -897,7 +897,7 @@ call_handlers (struct MHD_Connection *con, #ifdef HTTPS_SUPPORT if (con->tls_read_ready) - read_ready = MHD_YES; + read_ready = true; #endif /* HTTPS_SUPPORT */ if (!force_close) { @@ -1662,7 +1662,7 @@ thread_main_handle_connection (void *data) &rs), FD_ISSET (con->socket_fd, &ws), - MHD_NO)) + false)) goto exit; } #ifdef HAVE_POLL @@ -3061,7 +3061,7 @@ MHD_run_from_select (struct MHD_Daemon *daemon, read_fd_set), FD_ISSET (ds, write_fd_set), - MHD_NO); + false); } } @@ -3442,7 +3442,7 @@ MHD_poll_all (struct MHD_Daemon *daemon, call_handlers (pos, 0 != (p[poll_server+i].revents & POLLIN), 0 != (p[poll_server+i].revents & POLLOUT), - MHD_NO); + false); i++; } #if defined(HTTPS_SUPPORT) && defined(UPGRADE_SUPPORT) @@ -3936,9 +3936,9 @@ MHD_epoll (struct MHD_Daemon *daemon, /* FIXME: use (0 != pos->epoll_state & MHD_EPOLL_STATE_READ_READY) ? MHD_YES : MHD_NO * and (0 != pos->epoll_state & MHD_EPOLL_STATE_WRITE_READY) ? MHD_YES : MHD_NO */ call_handlers (pos, - (MHD_EVENT_LOOP_INFO_READ == pos->event_loop_info) ? MHD_YES : MHD_NO, - (MHD_EVENT_LOOP_INFO_WRITE == pos->event_loop_info) ? MHD_YES : MHD_NO, - MHD_NO); + MHD_EVENT_LOOP_INFO_READ == pos->event_loop_info, + MHD_EVENT_LOOP_INFO_WRITE == pos->event_loop_info, + false); if (MHD_EPOLL_STATE_IN_EREADY_EDLL == (pos->epoll_state & (MHD_EPOLL_STATE_SUSPENDED | MHD_EPOLL_STATE_IN_EREADY_EDLL))) {