BUG/MINOR: fd: Don't clear the update_mask in fd_insert.
authorOlivier Houchard <ohouchard@haproxy.com>
Tue, 3 Apr 2018 17:06:18 +0000 (19:06 +0200)
committerWilly Tarreau <w@1wt.eu>
Tue, 3 Apr 2018 17:38:15 +0000 (19:38 +0200)
commit8ef1a6b0d8c2ea1d8075e0b757007f05527952b8
tree8365d6fd87bef189283b3b50fd29745244f1ce77
parent2500fc2c3443f69bc05de53d0516da373d2f0cc1
BUG/MINOR: fd: Don't clear the update_mask in fd_insert.

Clearing the update_mask bit in fd_insert may lead to duplicate insertion
of fd in fd_updt, that could lead to a write past the end of the array.
Instead, make sure the update_mask bit is cleared by the pollers no matter
what.

This should be backported to 1.8.
[wt: warning: 1.8 doesn't have the lockless fdcache changes and will
 require some careful changes in the pollers]
include/proto/fd.h
src/ev_epoll.c
src/ev_kqueue.c
src/ev_poll.c
src/ev_select.c