ssb: More uv_async_send paranoia still. #96
All checks were successful
Build Tilde Friends / Build-All (push) Successful in 22m51s

This commit is contained in:
Cory McWilliams 2025-01-02 13:01:09 -05:00
parent 3cdbac5c22
commit 639fce376a

View File

@ -2719,7 +2719,8 @@ static void _tf_ssb_connection_finalizer(JSRuntime* runtime, JSValue value)
static void _tf_ssb_connection_process_message_async(uv_async_t* async)
{
tf_ssb_connection_t* connection = async->data;
if (!connection->is_closing && _tf_ssb_connection_box_stream_recv(connection))
/* The receive may initiate a close, so this order is important. */
if (_tf_ssb_connection_box_stream_recv(connection) && !connection->is_closing)
{
uv_async_send(&connection->async);
}