diff options
author | Keith Seitz <keiths@redhat.com> | 2025-03-27 08:46:39 -0700 |
---|---|---|
committer | Keith Seitz <keiths@redhat.com> | 2025-03-28 08:15:52 -0700 |
commit | 43ac3df61492b94bf13c11bd98c9f9541e92d3b0 (patch) | |
tree | 04209fca1d97766fe60f441a256c9d91e75fac28 /gdb/testsuite | |
parent | 41f0b410f5dc59ae89b7ec87bc3601d38b2030c8 (diff) | |
download | binutils-43ac3df61492b94bf13c11bd98c9f9541e92d3b0.zip binutils-43ac3df61492b94bf13c11bd98c9f9541e92d3b0.tar.gz binutils-43ac3df61492b94bf13c11bd98c9f9541e92d3b0.tar.bz2 |
Fix gstack issues
With commit fb2ded33c1e519659743047ed7817166545b6d91, I added
Fedora's gstack script to gdb. Some issues have arisen since
then, and this patch addresses those issues:
. As Sam James recently noted[1], PKGVERSION and VERSION
need to be quoted.
. A Fedora user reported the misuse of --readnever, which
causes gstack to omit filename and line number information in the
backtrace[Red Hat BZ 2354997].
[1] https://inbox.sourceware.org/gdb-patches/d19d6bc17e0a160ce27fc572079f11a587c0e168.1742424869.git.sam@gentoo.org/
Bug: https://bugzilla.redhat.com/show_bug.cgi?id=2354997
Diffstat (limited to 'gdb/testsuite')
-rw-r--r-- | gdb/testsuite/gdb.base/gstack.exp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/gdb/testsuite/gdb.base/gstack.exp b/gdb/testsuite/gdb.base/gstack.exp index 8df36b1..89be676 100644 --- a/gdb/testsuite/gdb.base/gstack.exp +++ b/gdb/testsuite/gdb.base/gstack.exp @@ -1,4 +1,4 @@ -# Copyright (C) 2024 Free Software Foundation, Inc. +# Copyright (C) 2024-2025 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -62,8 +62,10 @@ if { ![gdb_assert { ![expr {$res < 0 || $res == ""}] } $test] } { set test "got backtrace" set saw_backtrace false set no_awk false +set location_re ${srcfile}:${decimal} + gdb_expect { - -i "$res" -re "#0 +(0x\[0-9a-f\]+ in )?main \(\).*\r\nGSTACK-END\r\n\$" { + -i "$res" -re "#0 +(0x\[0-9a-f\]+ in )?main \(\).*$location_re.*\r\nGSTACK-END\r\n\$" { set saw_backtrace true pass $test exp_continue |