1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-20 10:24:14 +03:00

./mtr --gdb='b mysql_parse;r'

--gdb now accepts an argument, it will be passed to gdb as a command.
multiple commands can be separated by a (non-standard and not escapable)
delimiter - semicolon (;).

Old usage with a bare --gdb continues to work too, of course.
This commit is contained in:
Sergei Golubchik
2018-03-30 23:13:17 +02:00
parent 041e9de6f8
commit 339b905579

View File

@ -1133,7 +1133,7 @@ sub command_line_setup {
'debug' => \$opt_debug, 'debug' => \$opt_debug,
'debug-common' => \$opt_debug_common, 'debug-common' => \$opt_debug_common,
'debug-server' => \$opt_debug_server, 'debug-server' => \$opt_debug_server,
'gdb' => \$opt_gdb, 'gdb:s' => sub { $opt_gdb = $_[1] || '#' },
'client-gdb' => \$opt_client_gdb, 'client-gdb' => \$opt_client_gdb,
'manual-gdb' => \$opt_manual_gdb, 'manual-gdb' => \$opt_manual_gdb,
'manual-lldb' => \$opt_manual_lldb, 'manual-lldb' => \$opt_manual_lldb,
@ -5654,7 +5654,11 @@ shell sleep 1
target remote | /usr/lib64/valgrind/../../bin/vgdb target remote | /usr/lib64/valgrind/../../bin/vgdb
EOF EOF
} else { } else {
mtr_tofile($gdb_init_file, "set args @$$args $input\n"); mtr_tofile($gdb_init_file,
join("\n",
"set args @$$args $input",
split /;/, $opt_gdb
));
} }
if ( $opt_manual_gdb ) if ( $opt_manual_gdb )