Skip to content

9.5.26: the goodbye lingers until it is read - #296

Merged
jclauzel merged 1 commit into
mainfrom
zxnu04
Aug 24, 2026
Merged

jclauzel merged 1 commit into
mainfrom
zxnu04

Conversation

@jclauzel

Copy link
Copy Markdown
Owner

The PC half of ZXNextRemote 0.9.52 (jclauzel/ZXNextRemote#86) — hardware-confirmed together.

/forceexit against ZXNR ended the session but not the application, and the far console told the story: every command echoed except the quit, then "Connection closed." Both servers here answered the Poll with the goodbye and slammed the socket shut in the same breath — frame and FIN arriving together over the ESP — and ZXNR's listener (before 0.9.52) examined the close first, discarding the goodbye unread. The dot never showed the bug because its loop reads first.

After sending any goodbye ('Q', or the marked exit), both servers (zxnu_workers and nextsync5) now drain until the peer closes — bounded at 2 s — so the FIN can only ever follow the goodbye. This fixes the exit for every ZXNR 0.9.47–0.9.51 build in the field without an update; the dot closes within milliseconds of reading 'Q', so the wait is invisible there.

Full suite green (22 files).

🤖 Generated with Claude Code

/forceexit against ZX Next Remote ended the session but not the
application, and the far console told the story: every command echoed
except the quit, then 'Connection closed.'. Both servers here answered
the Poll with the goodbye and slammed the socket shut in the same
breath - and ZXNR's listener (before 0.9.52) examined the close first,
discarding the goodbye unread. The dot never showed it because its loop
reads first.

After sending a goodbye ('Q', or the marked exit), both servers now
DRAIN until the peer closes - bounded at 2 s - so the FIN can only ever
follow the goodbye. This fixes the exit for every ZXNR 0.9.47-0.9.51
build in the field without asking anyone to update; the dot closes
within milliseconds of reading 'Q', so the wait is invisible there.
ZXNR 0.9.52 fixes its half too (frames are read before the close
verdict, and a requested exit skips the press-any-key hold).

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@jclauzel
jclauzel merged commit 4e827de into main Aug 24, 2026
3 checks passed
@jclauzel
jclauzel deleted the zxnu04 branch August 24, 2026 15:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant