summaryrefslogtreecommitdiff
path: root/Lib/platform.py
diff options
context:
space:
mode:
authorVictor Stinner <vstinner@redhat.com>2019-06-27 09:04:28 +0200
committerGitHub <noreply@github.com>2019-06-27 09:04:28 +0200
commita719c8f4bd3cc5b1d98700c15c4a818f4d5617a4 (patch)
tree0da7921923adbfc1a9ac4c84d0e7b22ce8b17bbb /Lib/platform.py
parent4c26abd14f1b7242998eb2f7756aa375e0fe714f (diff)
downloadcpython-git-a719c8f4bd3cc5b1d98700c15c4a818f4d5617a4.tar.gz
bpo-35389: platform.platform() calls libc_ver() without executable (GH-14418)
When libc_ver() is called with an executable, the os.confstr('CS_GNU_LIBC_VERSION') fast-path cannot be taken. Modify platform.platform() to call libc_ver() without executable, instead of calling libc_ver(sys.executable), since sys.executable is already the default value.
Diffstat (limited to 'Lib/platform.py')
-rwxr-xr-xLib/platform.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/platform.py b/Lib/platform.py
index 6fbb7b08c5..ed41edc98f 100755
--- a/Lib/platform.py
+++ b/Lib/platform.py
@@ -1202,7 +1202,7 @@ def platform(aliased=0, terse=0):
elif system in ('Linux',):
# check for libc vs. glibc
- libcname, libcversion = libc_ver(sys.executable)
+ libcname, libcversion = libc_ver()
platform = _platform(system, release, machine, processor,
'with',
libcname+libcversion)