From 2c7e952f1cf1a7f28c99d8834d9b08dce920a65e Mon Sep 17 00:00:00 2001 From: Josh Gao Date: Tue, 27 Oct 2015 16:46:15 -0700 Subject: [PATCH] Allow gdbrunner.start_gdbserver to not upload gdbserver. Change-Id: I59239c3989ccd91755407e65b0d2f8183482564c --- python-packages/gdbrunner/__init__.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/python-packages/gdbrunner/__init__.py b/python-packages/gdbrunner/__init__.py index 564df0429..5ece37547 100644 --- a/python-packages/gdbrunner/__init__.py +++ b/python-packages/gdbrunner/__init__.py @@ -144,7 +144,7 @@ def start_gdbserver(device, gdbserver_local_path, gdbserver_remote_path, Args: device: ADB device to start gdbserver on. - gdbserver_local_path: Host path to push gdbserver from. + gdbserver_local_path: Host path to push gdbserver from, can be None. gdbserver_remote_path: Device path to push gdbserver to. target_pid: PID of device process to attach to. run_cmd: Command to run on the device. @@ -159,7 +159,8 @@ def start_gdbserver(device, gdbserver_local_path, gdbserver_remote_path, assert target_pid is None or run_cmd is None # Push gdbserver to the target. - device.push(gdbserver_local_path, gdbserver_remote_path) + if gdbserver_local_path is not None: + device.push(gdbserver_local_path, gdbserver_remote_path) # Run gdbserver. gdbserver_cmd = [gdbserver_remote_path, "--once",