Improve os.environ propagation #2264

This commit is contained in:
Thomas Nagy 2019-11-03 10:23:31 +01:00
parent 9da14a3356
commit 2931163e56
No known key found for this signature in database
GPG Key ID: 49B4C67C05277AAA
1 changed files with 1 additions and 1 deletions

View File

@ -891,7 +891,7 @@ def run_prefork_process(cmd, kwargs, cargs):
"""
Delegates process execution to a pre-forked process instance.
"""
if not 'env' in kwargs:
if not kwargs.get('env'):
kwargs['env'] = dict(os.environ)
try:
obj = base64.b64encode(cPickle.dumps([cmd, kwargs, cargs]))