[PATCH] sshpeer: forward stdout of remote "hg init" to appropriate output channel

Augie Fackler raf at durin42.com
Tue Oct 14 14:42:47 CDT 2014


On Tue, Oct 14, 2014 at 10:53:58PM +0900, Yuya Nishihara wrote:
> # HG changeset patch
> # User Yuya Nishihara <yuya at tcha.org>
> # Date 1413291579 -32400
> #      Tue Oct 14 21:59:39 2014 +0900
> # Node ID cc4be0f3d54ce2cdbfe6d6c8bc25de74d07b437c
> # Parent  75d0edb68b417964110e3fcd69187c867f31a119
> sshpeer: forward stdout of remote "hg init" to appropriate output channel

Seems reasonable.

>
> Otherwise, commandserver channel could be corrupted.

This makes me wonder if we should make out be a required param for util.system.

>
> diff --git a/mercurial/sshpeer.py b/mercurial/sshpeer.py
> --- a/mercurial/sshpeer.py
> +++ b/mercurial/sshpeer.py
> @@ -52,7 +52,7 @@ class sshpeer(wireproto.wirepeer):
>                  util.shellquote("%s init %s" %
>                      (_serverquote(remotecmd), _serverquote(self.path))))
>              ui.debug('running %s\n' % cmd)
> -            res = util.system(cmd)
> +            res = util.system(cmd, out=ui.fout)
>              if res != 0:
>                  self._abort(error.RepoError(_("could not create remote repo")))
>
> _______________________________________________
> Mercurial-devel mailing list
> Mercurial-devel at selenic.com
> http://selenic.com/mailman/listinfo/mercurial-devel


More information about the Mercurial-devel mailing list