提交 1c8c8a1e 编写于 作者: R Rudá Moura

avocado app: Review command line option regarding gdb.

From the current command line `--gdb-enable-core` replace it with
the new command line `--gdb-coredump {on,off}`, set default to `off`.

Use `--gdb-coredump=on` to behave like `--gdb-enable-core`.
Signed-off-by: NRudá Moura <rmoura@redhat.com>
上级 0bf10661
......@@ -46,8 +46,8 @@ class GDB(plugin.Plugin):
'BINARY_PATH is optional and if omitted '
'will apply to all binaries'))
gdb_grp.add_argument('--gdb-enable-core', action='store_true',
default=False,
gdb_grp.add_argument('--gdb-coredump', choices=('on', 'off'),
default='off',
help=('Automatically generate a core dump when the'
' inferior process received a fatal signal '
'such as SIGSEGV or SIGABRT'))
......@@ -79,8 +79,7 @@ class GDB(plugin.Plugin):
runtime.GDB_PRERUN_COMMANDS['binary'] = commands_path
else:
runtime.GDB_PRERUN_COMMANDS[''] = commands
if app_args.gdb_enable_core:
runtime.GDB_ENABLE_CORE = True
runtime.GDB_ENABLE_CORE = True if app_args.gdb_coredump == 'on' else False
runtime.GDB_PATH = app_args.gdb_path
runtime.GDBSERVER_PATH = app_args.gdbserver_path
except AttributeError:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册