fix(#710): init flserial mutexes before the reader thread can use them
fl_open started SerialThread and only then called mtx_init. Upstream's thread locked a mutex only after its first read returned data, so the gap rarely mattered; #710's room check locks inFifo_mutex on the thread's first pass, which made the race reachable on every connect. The mutexes are now initialised right after the FlSerial is allocated, before open() can throw, so _fl_close_slot also never destroys an uninitialised mutex after a failed open. Both copies stay identical. Found by the pre-PR Gemini review. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>feat/702-lossless-serial
parent
845b0f1e55
commit
1d38767b72
Loading…
Reference in new issue