mirror of
https://github.com/MariaDB/server.git
synced 2025-01-17 04:22:27 +01:00
Improve gdb coredump
This commit is contained in:
parent
b8413de10d
commit
c61516c381
1 changed files with 5 additions and 3 deletions
|
@ -25,6 +25,8 @@ use File::Temp qw/ tempfile tempdir /;
|
|||
sub _gdb {
|
||||
my ($core_name)= @_;
|
||||
|
||||
print "\nTrying 'gdb' to get a backtrace\n";
|
||||
|
||||
return unless -f $core_name;
|
||||
|
||||
my $dir = tempdir( CLEANUP => 1 );
|
||||
|
@ -35,7 +37,7 @@ sub _gdb {
|
|||
"quit\n";
|
||||
|
||||
# Find out name of binary that generated core
|
||||
my $list= `gdb -c $core_name -x $tmp_name -q 2>&1`
|
||||
my $list= `gdb -c $core_name -x $tmp_name -batch 2>&1`
|
||||
or return;
|
||||
|
||||
my $binary;
|
||||
|
@ -47,9 +49,9 @@ sub _gdb {
|
|||
|
||||
return unless $binary;
|
||||
|
||||
print "Generated by '$binary'\n";
|
||||
print " - core generated by '$binary'\n";
|
||||
|
||||
my $list= `gdb $binary -c $core_name -x $tmp_name -q 2>&1`
|
||||
my $list= `gdb $binary -c $core_name -x $tmp_name -batch 2>&1`
|
||||
or return;
|
||||
|
||||
print $list, "\n";
|
||||
|
|
Loading…
Reference in a new issue