Commit Graph
2287 Commits
Author SHA1 Message Date
Evgeny Grin (Karlson2k) 58cb96811c MHD_epoll(): call handler depending on read/write ready state instead of loop state. 2017-02-19 23:10:51 +03:00
Evgeny Grin (Karlson2k) d9b6e400f8 Changed poll()/select()/epoll monitoring logic:
connections monitored for incoming data only when expecting any incoming data;
connections always monitored for disconnection and out-of-band data;
connections are closed faster in case of any error conditions;
fixed non-zero timeout in poll() mode with MHD_EVENT_LOOP_INFO_BLOCK connections.
2017-02-19 23:03:35 +03:00
Evgeny Grin (Karlson2k) b473e12131 call_handlers(): use 'bool' type for parameters 2017-02-19 19:08:58 +03:00
Evgeny Grin (Karlson2k) f05715b71f call_handlers(): no need to call read or write handler in case of hard error 2017-02-19 19:00:23 +03:00
Evgeny Grin (Karlson2k) 0c8a6adb18 Simplified checks for internal polling thread. 2017-02-19 18:37:55 +03:00
Christian Grothoff 1689dae34a remove gl_ prefix, seems to help silioprog 2017-02-19 11:57:56 +01:00
Christian Grothoff 82d65c48ed replace tsearch test with code from gnulib, to hopefully address silviprog's android problems 2017-02-16 11:20:50 +01:00
Christian Grothoff f154b0ef88 bump dates and versions and update ChangeLog 2017-02-15 13:38:06 +01:00
Christian Grothoff d6dd85a3e6 convert client_aware to 'bool' 2017-02-15 13:34:22 +01:00
Christian Grothoff d170754b7d convert tls_closed to 'bool' 2017-02-15 13:32:39 +01:00
Christian Grothoff 925adb3889 convert clean_ready to 'bool' 2017-02-15 13:31:36 +01:00
Christian Grothoff e5fd7e14da convert have_dhparams to 'bool' 2017-02-15 13:29:18 +01:00
Christian Grothoff 3b2c0e1436 convert upgrade_fd_in_epoll to 'bool' 2017-02-15 13:28:32 +01:00
Christian Grothoff f9c239ec2a convert listen_socket_in_epoll to 'bool' 2017-02-15 13:27:42 +01:00
Christian Grothoff 2eb1573d56 fix race related to MHD_quiesce_daemon setting the listen socket to -1 which may disrupt concurrent non-locking activities by instead setting a flag (which suffices given the document semantics of MHD_quiesce_daemon()); renaming the socket_fd to listen_fd to distinguish it better by name 2017-02-15 13:25:50 +01:00
Christian Grothoff 2a815fe333 convert have_chunked_upload to 'bool' type 2017-02-15 11:48:37 +01:00
Christian Grothoff 78b14cd3d3 remove dead flag 2017-02-15 11:46:54 +01:00
Christian Grothoff d41652a6ed convert read_closed to 'bool' type 2017-02-15 11:46:05 +01:00
Christian Grothoff ae43b469e0 fix use of 'signal_done' in test 2017-02-14 18:46:11 +01:00
Christian Grothoff 8145670329 found another race, just with partial work-around for now; also init errno in all cases 2017-02-14 18:39:10 +01:00
Christian Grothoff ba9f1fc809 eliminate non-trival cleanup race (rare, only for thread-per-connection) 2017-02-14 18:06:59 +01:00
Christian Grothoff 3ba8a0c8b9 convert 'thread_joined' to bool 2017-02-14 18:00:17 +01:00
Christian Grothoff 8a84902f74 mark 'was_closed' as volatile; move connection resumption to end of upgrade routine to avoid race issue; eliminate dead code 2017-02-14 17:08:40 +01:00
Christian Grothoff 73e423312c add extra check, make it work with OpenSSL 1.1, eliminate dead code, some formatting 2017-02-14 16:59:10 +01:00
Christian Grothoff f1512b46b2 convert more int to bool 2017-02-14 16:48:35 +01:00
Christian Grothoff 805182fb26 avoid races with application upon connection upgrade: update state/response before calling MHD_response_execute_upgrade_ 2017-02-14 16:22:24 +01:00
Christian Grothoff d3a1aa3b45 modernize test case 2017-02-14 16:04:11 +01:00
Christian Grothoff 4a35b86796 remove unnecessary silly race to set socket_fd to -1 (harmless, but not required, confuses race checkers) 2017-02-14 15:56:45 +01:00
Christian Grothoff 205a3c20a2 mark 'shutdown' as volatile, and convert to bool 2017-02-14 15:54:34 +01:00
Christian Grothoff 648b65aa6c better fix for #4884 avoiding the problematic detach and the ERSCH-issue 2017-02-12 09:46:22 +01:00
Christian Grothoff 2e826fb4ee fix #4884 2017-02-12 09:42:23 +01:00
Christian Grothoff 4cd33c30b0 fix #4887 2017-02-12 09:38:44 +01:00
Christian Grothoff 9aa15f708b fix #4888 2017-02-12 09:35:38 +01:00
Evgeny Grin (Karlson2k) 47fdebac4b Rewrote epoll handling: handle all connections instead of drying last active 2017-02-08 22:44:21 +03:00
Christian Grothoff eba022ce02 shutdown triggered select is not true for FreeBSD 2017-02-01 00:09:29 +01:00
Christian Grothoff b98468404c avoid c99 construct, we do not yet require c99 elsewhere 2017-01-31 13:28:14 +01:00
Evgeny Grin (Karlson2k) c623d35dcc test_large_put: added poll() and epoll testing. 2017-01-23 00:10:03 +03:00
Evgeny Grin (Karlson2k) 2618c8c42f test_large_put: added test with incremental read and limited buffer 2017-01-23 00:10:03 +03:00
Evgeny Grin (Karlson2k) 2ed00da9ba test_large_put: added verbosity 2017-01-23 00:10:03 +03:00
Evgeny Grin (Karlson2k) c58fcc7391 test_large_put: initialise test buffer with varied data to detect more errors. 2017-01-23 00:10:02 +03:00
Evgeny Grin (Karlson2k) f3010a183c test_large_put: support incremental reading of incoming data 2017-01-23 00:10:02 +03:00
Evgeny Grin (Karlson2k) a610b8cc90 test_large_put: use proper types for size variables 2017-01-23 00:09:57 +03:00
Evgeny Grin (Karlson2k) b5b3e2fee2 test_large_put: renamed functions for readability 2017-01-23 00:09:57 +03:00
Evgeny Grin (Karlson2k) b6adf207b3 test_large_put: updated to use correct check for "11" in name and return '99' in case of system failures. 2017-01-23 00:09:51 +03:00
Evgeny Grin (Karlson2k) 44eec40651 send_param_adapter(): improved var name, used correct var type. 2017-01-21 21:50:17 +03:00
Evgeny Grin (Karlson2k) 313e750c65 Fixed processing epoll with many connections to accept.
If 'accept_pending' were set to 'true' not connection transfer occurred.
Additionally 'accept_pending' never reset to false.
2017-01-21 21:42:05 +03:00
Christian Grothoff d196c6cd64 fix FIXME about 128 connection limit; fix uninitialized 'fd' variable in send_param_adapter (when was this introduced?), change 'at_limit' type to 'bool' 2017-01-13 14:30:14 +01:00
Evgeny Grin (Karlson2k) b0b8633356 Added FIXME comment 2017-01-09 22:09:28 +03:00
Evgeny Grin (Karlson2k) 87c722090c Fixed processing of data in TLS buffers in epoll mode if more than 128 connections are ready 2017-01-09 21:55:51 +03:00
Evgeny Grin (Karlson2k) 491d411a01 Added FIXME comments 2017-01-08 23:50:27 +03:00