* src/process.c (server_accept_connection): Fix assertion (bug#80237).

This commit is contained in:
Eli Zaretskii 2026-02-10 17:09:56 +02:00
parent f2b81c38c2
commit d91d8c98f8

View file

@ -5137,11 +5137,15 @@ server_accept_connection (Lisp_Object server, int channel)
/* If the server process is locked to this thread, lock the client
process to the same thread, otherwise clear the thread of its I/O
descriptors. */
eassert (!fd_callback_info[p->infd].thread);
if (NILP (ps->thread))
set_proc_thread (p, NULL);
{
eassert (!fd_callback_info[p->infd].thread);
set_proc_thread (p, NULL);
}
else
{
eassert (!fd_callback_info[p->infd].thread
|| fd_callback_info[p->infd].thread == XTHREAD (ps->thread));
eassert (XTHREAD (ps->thread) == current_thread);
set_proc_thread (p, XTHREAD (ps->thread));
}