| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
| |
Note: TCP half-close is reported by WSAPoll() as POLLHUP event.
(e.g. TCP half-close from shutdown(fd, SHUT_WR))
TODO: If performance tests of select() vs WSAPoll() do not show a
a measurable difference, select() may be preferred over WSAPoll().
For now, make both "poll" and "select" available options in _WIN32.
(On other platforms, lighttpd build does not built code to use select()
when poll() is available on the platform.)
|
|
|
|
| |
use -lws2_32 instead of -lwsock32
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
_WIN32 SOCKET (long long unsigned) handles are assigned differently
from how POSIX allocates file descriptors (lowest number available).
On _WIN32, the SOCKET descriptor should not be used to index an array
of (fdnode *), so this commit provides an alternative method to store
(fdnode *) for use by select() and by WSAPoll().
select(): commonly used unix select() idioms may be incorrect on _WIN32
https://devblogs.microsoft.com/oldnewthing/20221102-00/?p=107343
https://devblogs.microsoft.com/oldnewthing/20161221-00/?p=94985
WSAPoll():
https://learn.microsoft.com/en-us/windows/win32/api/winsock2/nf-winsock2-wsapoll
As of Windows 10 version 2004, when a TCP socket fails to connect,
(POLLHUP | POLLERR | POLLWRNORM) is indicated.
(note: this was broken in WSAPoll() in all earlier Windows versions)
|
|
|
|
| |
lighttpd directly uses native OS event handlers
|
|
|
|
|
| |
Illumos POLLRDHUP != EPOLLRDHUP; lighttpd implementation asserts()
(since lighttpd implementation defines FDEVENT_RDHUP as POLLRDHUP)
|
| |
|
|
|
|
|
| |
omit fdevent select() code if poll() avail
translate server.event-handler = "select" to "poll" when poll available
|
|
|
|
|
|
|
| |
fdevent.c no longer directly uses struct server *srv
srv->srvconf.max_fds (if set) is used to set rlimits
set max_conns in server.c after fdevent_init(), which sets srv->max_fds
using srv->srvconf.max_fds (if set) as input hint
|
| |
|
|
|
|
|
| |
inline fdevent_fdnode_interest()
avoid array lookup for (fdnode *) for various ops
|
|
|
|
| |
isolate fde_ndx to fdevent framework internals
|
|
|
|
| |
(avoid need to translate event flags between OS and lighttpd FDEVENT_*)
|
|
|
|
|
|
| |
event framework now calls interface to dispatch events rather than
itself implementing multiple interfaces for fdevent_process() to
be able to dispatch events generically.
|
|
|
|
|
|
|
|
|
| |
provide standard types in first.h instead of base.h
provide lighttpd types in base_decls.h instead of settings.h
reduce headers exposed by headers for core data structures
do not expose <pcre.h> or <stdlib.h> in headers
move stat_cache_entry to stat_cache.h
reduce use of "server.h" and "base.h" in headers
|
| |
|
|
|