misc: fix use of openssl cli (#46984)

This commit is contained in:
Benjamin Dauvergne 2020-09-24 17:55:18 +02:00
parent ea599862bf
commit 5a135f7bf2
1 changed files with 4 additions and 1 deletions

View File

@ -44,7 +44,10 @@ def _call_openssl(args):
Return a tuple made of the return code and the stdout output
'''
try:
process = subprocess.Popen(args=[_openssl] + args, stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
process = subprocess.Popen(args=[_openssl] + args,
stdout=subprocess.PIPE,
stderr=subprocess.STDOUT,
universal_newlines=True)
output = process.communicate()[0]
return process.returncode, output
except OSError: