Skip to content

Commit

Permalink
run inside xterm (kevoreilly#2251)
Browse files Browse the repository at this point in the history
  • Loading branch information
dsecuma authored Jul 30, 2024
1 parent 45a95d9 commit 78fc278
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions analyzer/linux/lib/core/packages.py
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,9 @@ def strace_analysis(self):
# Tricking strace into always showing PID on stderr output
# https://github.com/strace/strace/issues/278#issuecomment-1815914576
cmd = f"sudo strace -o /dev/stderr -s 800 -ttf {target_cmd}"
# If nohuman is set to yes, it's possible to interact with interactive scripts or programs via VNC.
if self.options.get("nohuman"):
cmd = f"sudo strace -o /dev/stderr -s 800 -ttf xterm -hold -e {target_cmd} &"
log.info(cmd)
self.proc = subprocess.Popen(
cmd, env={"XAUTHORITY": "/root/.Xauthority", "DISPLAY": ":0"}, stderr=subprocess.PIPE, shell=True
Expand Down

0 comments on commit 78fc278

Please sign in to comment.