Skip to content

Commit a3e19c4

Browse files
freedrikpalextercete
authored andcommitted
Avoid using shlex.split in ADBDriver
This aligns with how commands and arguments are treated for SSH. Signed-off-by: freedrikp <[email protected]>
1 parent af32a96 commit a3e19c4

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

labgrid/driver/adb.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import shlex
21
import subprocess
32

43
import attr
@@ -73,7 +72,7 @@ def on_deactivate(self):
7372
# Command Protocol
7473

7574
def _run(self, cmd, *, timeout=30.0, codec="utf-8", decodeerrors="strict"):
76-
cmd = [*self._base_command, "shell", *shlex.split(cmd)]
75+
cmd = [*self._base_command, "shell", cmd]
7776
result = subprocess.run(
7877
cmd,
7978
text=True, # Automatically decode using default UTF-8

0 commit comments

Comments
 (0)