mirror of
https://github.com/cirosantilli/linux-kernel-module-cheat.git
synced 2026-01-26 03:31:36 +01:00
run_cmd: factor out logging of run and rungdb
This commit is contained in:
11
rungdb
11
rungdb
@@ -79,13 +79,4 @@ if not args.no_continue:
|
||||
# which gets put on the kernel build root when python debugging scripts are enabled.
|
||||
cmd.extend(['-ex', 'continue'] + lx_symbols)
|
||||
cmd.extend(after)
|
||||
common.print_cmd(cmd)
|
||||
|
||||
# TODO eeval
|
||||
# "${common.root_dir}/eeval" "$cmd $after" "${common.run_dir}/rungdb.sh"
|
||||
|
||||
# Required, otherwise Ctrl + C kills Python and that kills GDB.
|
||||
# https://stackoverflow.com/questions/19807134/does-python-always-raise-an-exception-if-you-do-ctrlc-when-a-subprocess-is-exec
|
||||
signal.signal(signal.SIGINT, lambda *args: None)
|
||||
|
||||
sys.exit(subprocess.Popen(cmd, cwd=common.linux_variant_dir).wait())
|
||||
sys.exit(common.run_cmd(cmd, cmd_file=os.path.join(common.run_dir, 'rungdb.sh'), cwd=common.linux_variant_dir))
|
||||
|
||||
Reference in New Issue
Block a user