Mercurial > public > mercurial-scm > hg
diff hgext/factotum.py @ 39826:c31ce080eb75
py3: convert arguments, cwd and env to native strings when spawning subprocess
This keeps Windows happy.
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Sun, 23 Sep 2018 00:47:04 -0400 |
parents | a9524aea7cab |
children | 2372284d9457 |
line wrap: on
line diff
--- a/hgext/factotum.py Fri Sep 21 21:14:27 2018 -0400 +++ b/hgext/factotum.py Sun Sep 23 00:47:04 2018 -0400 @@ -49,6 +49,9 @@ import os from mercurial.i18n import _ +from mercurial.utils import ( + procutil, +) from mercurial import ( error, httpconnection, @@ -83,7 +86,7 @@ if 'user=' not in params: params = '%s user?' % params params = '%s !password?' % params - os.system("%s -g '%s'" % (_executable, params)) + os.system(procutil.tonativestr("%s -g '%s'" % (_executable, params))) def auth_getuserpasswd(self, getkey, params): params = 'proto=pass %s' % params