call gpg with LANG=C to prevent decoding issues

This commit is contained in:
Yann Leboulanger 2016-04-18 22:38:17 +02:00
parent e585c579cb
commit cc46d7b7d0

View file

@ -741,8 +741,10 @@ class GPG(object):
si = STARTUPINFO()
si.dwFlags = STARTF_USESHOWWINDOW
si.wShowWindow = SW_HIDE
env = os.environ
env['LANG'] = 'C'
return Popen(cmd, shell=False, stdin=PIPE, stdout=PIPE, stderr=PIPE,
startupinfo=si)
env=env, startupinfo=si)
def _read_response(self, stream, result):
# Internal method: reads all the stderr output from GPG, taking notice