[Python-checkins] cpython (merge 3.3 -> default): Merge #19855: restore use of LC_ALL, not LC_MESSAGES

r.david.murray python-checkins at python.org
Sat Jan 18 21:03:00 CET 2014


http://hg.python.org/cpython/rev/418212180bf1
changeset:   88558:418212180bf1
parent:      88555:1469c4fde8cd
parent:      88557:706354c4d8f5
user:        R David Murray <rdmurray at bitdance.com>
date:        Sat Jan 18 15:02:00 2014 -0500
summary:
  Merge #19855: restore use of LC_ALL, not LC_MESSAGES

files:
  Lib/uuid.py |  7 ++++---
  1 files changed, 4 insertions(+), 3 deletions(-)


diff --git a/Lib/uuid.py b/Lib/uuid.py
--- a/Lib/uuid.py
+++ b/Lib/uuid.py
@@ -321,9 +321,10 @@
             return None
 
     try:
-        # LC_MESSAGES to get English output, 2>/dev/null to
-        # prevent output on stderr
-        cmd = 'LC_MESSAGES=C %s %s 2>/dev/null' % (executable, args)
+        # LC_ALL to ensure English output, 2>/dev/null to prevent output on
+        # stderr (Note: we don't have an example where the words we search for
+        # are actually localized, but in theory some system could do so.)
+        cmd = 'LC_ALL=C %s %s 2>/dev/null' % (executable, args)
         with os.popen(cmd) as pipe:
             for line in pipe:
                 words = line.lower().split()

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list