Tools: sim_vehicle: make gdb-stopped work again

This commit is contained in:
Peter Barker 2016-11-22 22:15:20 +11:00
parent 7f2882f54b
commit e505635ddd
1 changed files with 3 additions and 2 deletions

View File

@ -465,7 +465,7 @@ def start_vehicle(binary, autotest, opts, stuff, loc):
if opts.callgrind:
cmd_name += " (callgrind)"
cmd.append("valgrind --tool=callgrind")
if opts.gdb:
if opts.gdb or opts.gdb_stopped:
cmd_name += " (gdb)"
cmd.append("gdb")
gdb_commands_file = tempfile.NamedTemporaryFile(delete=False)
@ -473,7 +473,8 @@ def start_vehicle(binary, autotest, opts, stuff, loc):
for breakpoint in opts.breakpoint:
gdb_commands_file.write("b %s\n" % (breakpoint,))
gdb_commands_file.write("r\n")
if not opts.gdb_stopped:
gdb_commands_file.write("r\n")
gdb_commands_file.close()
cmd.extend(["-x", gdb_commands_file.name])
cmd.append("--args")