]> granicus.if.org Git - python/commitdiff
Issue #7356: ctypes.util: Make parsing of ldconfig output locale independent.
authorMatthias Klose <doko@ubuntu.com>
Mon, 15 Mar 2010 13:46:04 +0000 (13:46 +0000)
committerMatthias Klose <doko@ubuntu.com>
Mon, 15 Mar 2010 13:46:04 +0000 (13:46 +0000)
Previous fix was only made to dead and removed code.

Lib/ctypes/util.py
Misc/NEWS

index bf1b6a012ae3de27f728e3638cd2949b07cddfc1..b2c514d558447169a30a48824541182456968ca8 100644 (file)
@@ -223,7 +223,7 @@ elif os.name == "posix":
 
             # XXX assuming GLIBC's ldconfig (with option -p)
             expr = r'\s+(lib%s\.[^\s]+)\s+\(%s' % (re.escape(name), abi_type)
-            f = os.popen('/sbin/ldconfig -p 2>/dev/null')
+            f = os.popen('LC_ALL=C LANG=C /sbin/ldconfig -p 2>/dev/null')
             try:
                 data = f.read()
             finally:
index 6359e7cb98f0bcce15655fd8378da4e77bdb10ec..591864fbfb3c688670907eda5021b62b0f571943 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -92,6 +92,9 @@ Core and Builtins
 Library
 -------
 
+- Issue #7356: ctypes.util: Make parsing of ldconfig output independent of the
+  locale.
+
 - Issue #25738: Stop BaseHTTPServer.BaseHTTPRequestHandler.send_error() from
   sending a message body for 205 Reset Content.  Also, don't send the
   Content-Type header field in responses that don't have a body.  Based on
@@ -6232,9 +6235,6 @@ Library
 
 - Issue #8140: Extend compileall to compile single files.  Add -i option.
 
-- Issue #7356: ctypes.util: Make parsing of ldconfig output independent of the
-  locale.
-
 - Issue #7774: Set sys.executable to an empty string if ``argv[0]`` has been set
   to an non existent program name and Python is unable to retrieve the real
   program name.