summaryrefslogtreecommitdiffstats
path: root/ssh.py
diff options
context:
space:
mode:
Diffstat (limited to 'ssh.py')
-rw-r--r--ssh.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/ssh.py b/ssh.py
index 7a37c36..d790d4a 100644
--- a/ssh.py
+++ b/ssh.py
@@ -19,7 +19,7 @@ def empackage(z, filename):
return '%s\n%d\n%s' % (filename,len(content), content)
-def connect(rhostport):
+def connect(rhostport, python):
main_exe = sys.argv[0]
l = (rhostport or '').split(':', 1)
rhost = l[0]
@@ -48,9 +48,9 @@ def connect(rhostport):
if not rhost:
- argv = ['python', '-c', pyscript]
+ argv = [python, '-c', pyscript]
else:
- argv = ['ssh'] + portl + [rhost, '--', "python -c '%s'" % pyscript]
+ argv = ['ssh'] + portl + [rhost, '--', "'%s' -c '%s'" % (python, pyscript)]
(s1,s2) = socket.socketpair()
def setup():
# runs in the child process