Uploaded April 2025 | Updated November 2026, 1 day ago
I noticed if I Ctrl-C into a program running under GDB, and it stops in some function I don't have source for (e.g. clock_nanasleep()), and then I type Ctrl-X A to enter TUI mode, my terminal gets screwed up. I can recover by typing "shell", then "reset ctrl-j", then "exit", and then "up" until I get into my own code, then CTRL-X A works. But why is the terminal screwed up in the first place? And how do I avoid it. (answer is *not* CTRL-L to redraw the screen).
I noticed if I Ctrl-C into a program running under GDB, and it stops in some function I don't have source for (e.g. clock_nanasleep()), and then I type Ctrl-X A to enter TUI mode, my terminal gets screwed up. I can recover by typing "shell", then "reset ctrl-j", then "exit", and then "up" until I get into my own code, then CTRL-X A works. But why is the terminal screwed up in the first place? And how do I avoid it. (answer is *not* CTRL-L to redraw the screen).










