crashinfo: Get local variable values in the gdb backtrace

This should make crash reports a bit more useful without having to ask
for additional information.

Reviewed by:	imp
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D42465

(cherry picked from commit 3e356fb885)
This commit is contained in:
Mark Johnston 2023-11-06 14:59:10 -05:00
parent 29667c6fcc
commit e26e6a98d4

View File

@ -236,7 +236,7 @@ echo
# kgdb via stdin and have to use a temporary file instead.
file=`mktemp /tmp/crashinfo.XXXXXX`
if [ $? -eq 0 ]; then
echo "bt" >> $file
echo "bt -full" >> $file
echo "quit" >> $file
${GDB%gdb}kgdb $KERNEL $VMCORE < $file
rm -f $file