]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
[gdb/testsuite] Fix gdb.threads/clone-attach-detach.exp
authorTom de Vries <tdevries@suse.de>
Thu, 17 Apr 2025 07:51:46 +0000 (09:51 +0200)
committerTom de Vries <tdevries@suse.de>
Thu, 17 Apr 2025 07:51:46 +0000 (09:51 +0200)
commit610f55b542e95dbfa438cfda92f29c2704e8409f
tree61f9e782dd4a3add6d9b0e48ae9a3fa966168574
parentfc0747d0b1520d880b44ebb9ff5ebb7588467a33
[gdb/testsuite] Fix gdb.threads/clone-attach-detach.exp

With test-case gdb.threads/clone-attach-detach.exp I usually get:
...
(gdb) attach <pid> &^M
Attaching to program: clone-attach-detach, process <pid>^M
[New LWP <lwp>]^M
(gdb) PASS: $exp: bg attach <n>: attach
[Thread debugging using libthread_db enabled]^M
Using host libthread_db library "/lib64/libthread_db.so.1".^M
...
but sometimes I run into:
...
(gdb) attach <pid> &^M
Attaching to program: clone-attach-detach, process <pid>^M
[New LWP <lwp>]^M
(gdb) [Thread debugging using libthread_db enabled]^M
Using host libthread_db library "/lib64/libthread_db.so.1".^M
FAIL: $exp: bg attach <n>: attach (timeout)
...

I managed to reproduce this using make target check-readmore and
READMORE_SLEEP=100.

Fix this using -no-prompt-anchor.

Tested on x86_64-linux.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
gdb/testsuite/gdb.threads/clone-attach-detach.exp