The previous event_baseloopbreak(base); did not work reliably. The reason is that exits the loop only during event_base_loop(base_, EVLOOP_ONCE); . Since the requested break is reset at the beginning of the loop https://github.com/libevent/libevent/blob/1af745d033678333752afcd8724f5d6351561b4e/event.c#L2000 . Using event_base_loopexit is also remembered if the call from another thread occurs during the phase outside of event_base_loop. It would be nice if this chnage/fix can go into libquiche.
The previous event_baseloopbreak(base); did not work reliably. The reason is that exits the loop only during
event_base_loop(base_, EVLOOP_ONCE);
. Since the requested break is reset at the beginning of the loop https://github.com/libevent/libevent/blob/1af745d033678333752afcd8724f5d6351561b4e/event.c#L2000 . Usingevent_base_loopexit
is also remembered if the call from another thread occurs during the phase outside ofevent_base_loop
. It would be nice if this chnage/fix can go into libquiche.