Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 82f6091

Browse files
committed
Merged revisions 78979 via svnmerge from
svn+ssh://[email protected]/python/trunk ........ r78979 | matthias.klose | 2010-03-15 14:42:23 +0100 (Mo, 15 Mär 2010) | 3 lines - Issue #7356: ctypes.util: Make parsing of ldconfig output independent of the locale. ........
1 parent a834975 commit 82f6091

2 files changed

Lines changed: 4 additions & 1 deletion

File tree

Lib/ctypes/util.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ def _findSoname_ldconfig(name):
205205
# XXX assuming GLIBC's ldconfig (with option -p)
206206
expr = r'(\S+)\s+\((%s(?:, OS ABI:[^\)]*)?)\)[^/]*(/[^\(\)\s]*lib%s\.[^\(\)\s]*)' \
207207
% (abi_type, re.escape(name))
208-
with contextlib.closing(os.popen('/sbin/ldconfig -p 2>/dev/null')) as f:
208+
with contextlib.closing(os.popen('LANG=C /sbin/ldconfig -p 2>/dev/null')) as f:
209209
data = f.read()
210210
res = re.search(expr, data)
211211
if not res:

Misc/NEWS

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -283,6 +283,9 @@ C-API
283283
Library
284284
-------
285285

286+
- Issue #7356: ctypes.util: Make parsing of ldconfig output independent of
287+
the locale.
288+
286289
- The internals of the subprocess module on POSIX systems have been replaced
287290
by an extension module (_posixsubprocess) so that the fork()+exec() can be
288291
done safely without the possibility of deadlock in multithreaded applications.

0 commit comments

Comments
 (0)