pkgsrc-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
lighttpd 1.4.45 patch to use level-triggered kqueue
*BSD maintainers: it has come to my attention that lighttpd uses kqueue
in edge-triggered mode, even though all other event mechanisms in
lighttpd use level-triggered, and lighttpd expects level-triggered
behavior.
This will be fixed in lighttpd 1.4.46, but lighttpd 1.4.46 is not
expected to be released for a few months, so please consider adding
the patch below to the *BSD lighttpd 1.4.45 packages in the meantime.
Please refer to https://redmine.lighttpd.net/issues/2788 for more
details on how this issue might affect *BSD users.
Cheers, Glenn
--- a/src/fdevent_freebsd_kqueue.c
+++ b/src/fdevent_freebsd_kqueue.c
@@ -75,14 +75,14 @@ static int fdevent_freebsd_kqueue_event_set(fdevents *ev, int fde_ndx, int fd, i
if (events == oevents) return fd;
if (addevents & FDEVENT_IN) {
- EV_SET(&kev[n], fd, EVFILT_READ, EV_ADD|EV_CLEAR, 0, 0, NULL);
+ EV_SET(&kev[n], fd, EVFILT_READ, EV_ADD, 0, 0, NULL);
n++;
} else if (delevents & FDEVENT_IN) {
EV_SET(&kev[n], fd, EVFILT_READ, EV_DELETE, 0, 0, NULL);
n++;
}
if (addevents & FDEVENT_OUT) {
- EV_SET(&kev[n], fd, EVFILT_WRITE, EV_ADD|EV_CLEAR, 0, 0, NULL);
+ EV_SET(&kev[n], fd, EVFILT_WRITE, EV_ADD, 0, 0, NULL);
n++;
} else if (delevents & FDEVENT_OUT) {
EV_SET(&kev[n], fd, EVFILT_WRITE, EV_DELETE, 0, 0, NULL);
Home |
Main Index |
Thread Index |
Old Index