Show More
@@ -20,6 +20,8 b' class remotelock(object):' | |||
|
20 | 20 | self.release() |
|
21 | 21 | |
|
22 | 22 | def _serverquote(s): |
|
23 | if not s: | |
|
24 | return s | |
|
23 | 25 | '''quote a string for the remote shell ... which we assume is sh''' |
|
24 | 26 | if re.match('[a-zA-Z0-9@%_+=:,./-]*$', s): |
|
25 | 27 | return s |
@@ -45,7 +47,10 b' class sshpeer(wireproto.wirepeer):' | |||
|
45 | 47 | sshcmd = self.ui.config("ui", "ssh", "ssh") |
|
46 | 48 | remotecmd = self.ui.config("ui", "remotecmd", "hg") |
|
47 | 49 | |
|
48 |
args = util.sshargs(sshcmd, |
|
|
50 | args = util.sshargs(sshcmd, | |
|
51 | _serverquote(self.host), | |
|
52 | _serverquote(self.user), | |
|
53 | _serverquote(self.port)) | |
|
49 | 54 | |
|
50 | 55 | if create: |
|
51 | 56 | cmd = '%s %s %s' % (sshcmd, args, |
General Comments 0
You need to be logged in to leave comments.
Login now