jart / bestline

ANSI Standard X3.64 Teletypewriter Command Session Library
Other
443 stars 29 forks source link

Freeze after C-q A-X #35

Closed MaxGyver83 closed 1 month ago

MaxGyver83 commented 1 month ago

How to reproduce

  1. Compile and execute bestline_example.
  2. Press Ctrl-q.
  3. Press Alt-Shift-x.
MaxGyver83 commented 1 month ago

OK, I think I understand it now: Alt-Shift-x = Escape Shift-x is special: SOS (Start of String) https://github.com/jart/bestline/blob/23c7046b6b97913769dadef5c6a53ae8d89e32d3/bestline.c#L1478 The "freeze" can be ended by pressing Ctrl-g ('\a').