2
0
mirror of https://gitlab.com/ita1024/waf.git synced 2024-11-22 09:57:15 +01:00

Force an encoding on config.log #1974

This commit is contained in:
Thomas Nagy 2017-06-02 21:17:09 +02:00
parent 578230789a
commit 377d09831b
No known key found for this signature in database
GPG Key ID: 49B4C67C05277AAA

View File

@ -328,7 +328,7 @@ def make_logger(path, name):
:type name: string
"""
logger = logging.getLogger(name)
hdlr = logging.FileHandler(path, 'w')
hdlr = logging.FileHandler(path, 'w', encoding=sys.stdout.encoding)
formatter = logging.Formatter('%(message)s')
hdlr.setFormatter(formatter)
logger.addHandler(hdlr)