From c82e88dd00d1b0b7fcfb4e5628d99611388cef6f Mon Sep 17 00:00:00 2001 From: rawnix ports Date: Sat, 26 Sep 2026 18:19:05 +0000 Subject: sync 2026-09-26 18:19 UTC 1672 files changed, 151396 insertions(+) --- core/readline/readline83-001 | 64 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 core/readline/readline83-001 (limited to 'core/readline/readline83-001') diff --git a/core/readline/readline83-001 b/core/readline/readline83-001 new file mode 100644 index 0000000..007eb87 --- /dev/null +++ b/core/readline/readline83-001 @@ -0,0 +1,64 @@ + READLINE PATCH REPORT + ===================== + +Readline-Release: 8.3 +Patch-ID: readline83-001 + +Bug-Reported-by: Dmitri A. Sergatskov +Bug-Reference-ID: +Bug-Reference-URL: + +Bug-Description: + +If an application uses readline's event hook, it is called while waiting for +input. There is a bug in the function that waits for available input that +causes it not to read that input under certain circumstances, resulting in +a loop where the event hook continues to be called, but there is no input +to stop it. + +Patch (apply with `patch -p0'): + +*** ../readline-8.3/input.c Fri May 2 09:29:05 2025 +--- input.c Tue Jul 8 15:37:13 2025 +*************** +*** 262,266 **** + tty = fileno (rl_instream); + +! /* Move this up here to give it first shot, but it can't set chars_avail */ + /* XXX - need rl_chars_available_hook? */ + if (rl_input_available_hook) +--- 262,267 ---- + tty = fileno (rl_instream); + +! /* Move this up here to give it first shot, but it can't set chars_avail, +! so we assume a single character is available. */ + /* XXX - need rl_chars_available_hook? */ + if (rl_input_available_hook) +*************** +*** 269,272 **** +--- 270,275 ---- + if (result == 0) + result = -1; ++ else ++ chars_avail = 1; + } + +*************** +*** 286,289 **** +--- 289,293 ---- + if (result <= 0) + return 0; /* Nothing to read. */ ++ result = -1; /* there is something, so check how many chars below */ + } + #endif +*** ../readline-8.3/patchlevel 2013-11-15 08:11:11.000000000 -0500 +--- patchlevel 2014-03-21 08:28:40.000000000 -0400 +*************** +*** 1,3 **** + # Do not edit -- exists only for use by patch + +! 0 +--- 1,3 ---- + # Do not edit -- exists only for use by patch + +! 1 -- cgit v1.3.1