summaryrefslogtreecommitdiff
path: root/third_party/waf/waflib/Logs.py
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/waf/waflib/Logs.py')
-rw-r--r--third_party/waf/waflib/Logs.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/third_party/waf/waflib/Logs.py b/third_party/waf/waflib/Logs.py
index 2a475169b9b..298411db51e 100644
--- a/third_party/waf/waflib/Logs.py
+++ b/third_party/waf/waflib/Logs.py
@@ -237,7 +237,10 @@ class formatter(logging.Formatter):
if rec.levelno >= logging.INFO:
# the goal of this is to format without the leading "Logs, hour" prefix
if rec.args:
- return msg % rec.args
+ try:
+ return msg % rec.args
+ except UnicodeDecodeError:
+ return msg.encode('utf-8') % rec.args
return msg
rec.msg = msg
@@ -276,9 +279,9 @@ def error(*k, **kw):
def warn(*k, **kw):
"""
- Wraps logging.warn
+ Wraps logging.warning
"""
- log.warn(*k, **kw)
+ log.warning(*k, **kw)
def info(*k, **kw):
"""