From a3f9ae6a1779a431cdc1dd5967f877501e913d01 Mon Sep 17 00:00:00 2001 From: adam Date: Tue, 29 Sep 2026 17:31:21 +0000 Subject: [PATCH] quit when input ends at the guess prompt At end of input (Ctrl-D, or stdin closed) read returns straight away with an empty guess, so the "Must be 5 letters" loop spun forever at full CPU. If the game's parent process was killed first, the subshell was left orphaned and spinning. Exit retrieve_guess when read hits EOF, pass that back through the retry prompts with a single recursive call, and quit from main. Co-Authored-By: Claude Opus 5.5 --- wordle | 28 +++++++++++++++++----------- 1 file changed, 17 insertions(+), 11 deletions(-) diff --git a/wordle b/wordle index cf9065e..1332835 100755 --- a/wordle +++ b/wordle @@ -58,7 +58,7 @@ function main() { for (( ROW; ROW