solanum-vs-hackint-and-char.../librb/src
Ed Kellett 59ea3c6753 Delay rehashing until we're not processing events
Fixes crash introduced by 0ab6dbbc65. It's
probably a regression since it defeats a system designed to stop this
from happening, but I didn't dig through the history.

rehash() closes listeners. If we happen to get a single epoll() result
that wants to first rehash and then accept a connection, the epoll info
will point to a freed rb_fde_t. Other selectors should have similar
problems, but we didn't investigate that.

rb_fde_ts are normally batched up and freed outside the event
processing, but as of the above commit close_listeners() screws that up
by closing pending FDs immediately in order to create new listeners.

I think it might be a bit better to revert this behaviour and simply not
close listeners if we are going to open new ones over them, but have
opted for the smallest reasonable change I can think of.

Helped-by: Eric Mertens <emertens@gmail.com>
2023-11-06 14:22:55 +00:00
..
arc4random.c Add semicolon to fix a compile error in librb/src/arc4random.c 2022-09-30 18:27:26 +01:00
balloc.c The rb_heap_block struct doesn't appear to be used anywhere 2021-07-31 00:09:08 -04:00
commio.c Delay rehashing until we're not processing events 2023-11-06 14:22:55 +00:00
crypt.c librb/src/crypt.c: rb_sha*_crypt_r: avoid UB pointer math 2022-08-24 20:03:22 -04:00
devpoll.c Fix Clang 6 compiler warnings 2019-09-15 11:28:48 +01:00
dictionary.c Mailmap and copyright update for Ariadne 2021-06-01 12:40:02 -04:00
epoll.c Remove ancient portability code (#361) 2022-08-24 20:53:52 -04:00
event.c Cast time_t to long long when printing 2022-07-01 03:43:36 -04:00
export-syms.txt Delay rehashing until we're not processing events 2023-11-06 14:22:55 +00:00
gnutls.c GNUTLS: Provide a default priority string, disable TLSv1.0 in it 2016-12-30 17:59:35 +00:00
gnutls_ratbox.h Remove hardcoded TLSv1 disables 2020-11-01 04:07:24 +00:00
helper.c librb/helper: pass our fd limit to the child 2022-10-21 03:04:09 -04:00
kqueue.c Fix Clang 6 compiler warnings 2019-09-15 11:28:48 +01:00
linebuf.c Remove ancient portability code (#361) 2022-08-24 20:53:52 -04:00
Makefile.am Remove Windows support 2021-07-30 14:17:47 -04:00
mbedtls.c librb mbedTLS: der_pubkey is used out of scope 2021-06-02 18:38:22 +00:00
mbedtls_ratbox.h Innovation by sed 2020-10-15 15:52:41 +01:00
nossl.c librb: Fix nossl 2019-09-15 12:33:56 +01:00
openssl.c OpenSSL 3.0 compatibility 2022-08-25 00:36:47 +00:00
openssl_ratbox.h OpenSSL: Support configuration of TLSv1.3 ciphersuites 2021-02-07 11:52:58 +00:00
patricia.c remove RB_IPV6 2017-08-20 12:54:46 +01:00
poll.c Remove ancient portability code (#361) 2022-08-24 20:53:52 -04:00
ports.c Remove stray semicolons (#339) 2022-06-10 18:07:25 +01:00
radixtree.c Mailmap and copyright update for Ariadne 2021-06-01 12:40:02 -04:00
rawbuf.c librb: rb_rawbuf_length: do something if soft assert fails 2017-07-29 22:46:10 +01:00
rb_lib.c Remove ancient portability code (#361) 2022-08-24 20:53:52 -04:00
rb_memory.c Remove the rest of the SVN id tags 2016-03-23 20:13:12 -04:00
sigio.c Remove ancient portability code (#361) 2022-08-24 20:53:52 -04:00
tools.c Remove ancient portability code (#361) 2022-08-24 20:53:52 -04:00
unix.c Remove ancient portability code (#361) 2022-08-24 20:53:52 -04:00
version.c.SH Innovation by sed 2020-10-15 15:52:41 +01:00