-
Notifications
You must be signed in to change notification settings - Fork 15.1k
Description
I was helping someone with a custom stop hook and we wanted to disable the usual stuff lldb prints out. Maybe there is a neat way but I settled on changing a bunch of settings, which works but corrupts the display of the line after the stop.
$ ./bin/lldb /tmp/test.o
(lldb) target create "/tmp/test.o"
Current executable set to '/tmp/test.o' (aarch64).
Set these settings so we print as little as possible on stop:
(lldb) settings set stop-line-count-before 0
(lldb) settings set stop-line-count-after 0
(lldb) settings set thread-stop-format ""
(lldb) settings set frame-format ""
Set a breakpoint:
(lldb) b main
Breakpoint 1: where = test.o`main + 12 at test.c:2:12, address = 0x0000000000000720
Run to the breakpoint:
(lldb) run
Process 959482 launched: '/tmp/test.o' (aarch64)
Process 959482 stopped
(lldb) lldb) << This has an extra lldb)
test.o │ test.c:2:12 │ breakpoint 1.1 << This is the status bar
The cursor is in the right place, and typing will overwrite the garbage characters, but it certainly looks strange.
(lldb) lldb)
|---- The cursor is here
I would expect to just see (lldb) as if I had run any other command.
Also if anything I would have expect it to not print (lldb) at all, if it wasn't printing some part of the stop output. Seems backwards that doing less would print more prompts, but perhaps this is not extra printed text but somehow moved text or text that was previously overwritten.
Again, just cosmetic, very easy for the user to recover from.