Categories
Linux Mastering Development Ubuntu

Prompt is marching across the screen when entering gdb TUI

I’m debugging a program:

// t.c
#include <assert.h>

int main() {
    assert(0);
    return 0;
}
gcc t.c -g
gdb ./a.out
(gdb) r
Starting program: /home/user/a.out 
a.out: t.c:4: main: Assertion `0' failed.

Program received signal SIGABRT, Aborted.
__GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
50  ../sysdeps/unix/sysv/linux/raise.c: No such file or directory.
(gdb) 

When entering TUI by ctrl-x a and up to check upper frame, it’s a mess. The prompts are supposed to be aligned but now the it’s marching across the screen:

gdb

Even leaving gdb and returning back to bash, the output is still a mess.

I’m using gdb 9.2 and ubuntu 20.04.

Leave a Reply

Your email address will not be published. Required fields are marked *