Submitter | Matt Harbison |
---|---|
Date | Dec. 18, 2018, 6:56 a.m. |
Message ID | <932ed8a051de1d7ef7ae.1545116171@Envy> |
Download | mbox | patch |
Permalink | /patch/37231/ |
State | Accepted |
Headers | show |
Comments
Patch
diff --git a/contrib/hgclient.py b/contrib/hgclient.py --- a/contrib/hgclient.py +++ b/contrib/hgclient.py @@ -33,7 +33,12 @@ def connectpipe(path=None, extraargs=()) cmdline += [b'-R', path] cmdline.extend(extraargs) - server = subprocess.Popen(cmdline, stdin=subprocess.PIPE, + def tonative(cmdline): + if os.name != r'nt': + return cmdline + return [arg.decode("utf-8") for arg in cmdline] + + server = subprocess.Popen(tonative(cmdline), stdin=subprocess.PIPE, stdout=subprocess.PIPE) return server