[issue24266] raw_input + readline: Ctrl+C during search breaks readline

Martin Panter report at bugs.python.org
Sun May 24 12:05:37 CEST 2015


Martin Panter added the comment:

I suspect this is actually a bug with Gnu Readline. The same issue exists in GDB.

When a signal handler (such as SIGINT) raises an exception to abort the input, Python calls rl_free_line_state(). The documentation for that function, <https://cnswww.cns.cwru.edu/php/chet/readline/readline.html#IDX341> says Readline’s own SIGINT handler (which Python doesn’t normally actually use) also calls it to abort the current line. It lists various states that are “freed”. Although the search state is not in the list, it seems like it should be.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue24266>
_______________________________________


More information about the Python-bugs-list mailing list