From: Hirokazu Yamamoto Date: Thu, 4 Sep 2008 11:21:28 +0000 (+0000) Subject: Issue #3762: platform.architecture() fails if python is lanched via its symbolic... X-Git-Tag: v2.5.3c1~49 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=f4e2ccf3b3191a796b0b8631f686363b3b97dcce;p=python Issue #3762: platform.architecture() fails if python is lanched via its symbolic link. Reviewed Amaury Forgeot d'Arc (Backport of r66213) --- diff --git a/Lib/platform.py b/Lib/platform.py index f34e735592..0df65db80c 100755 --- a/Lib/platform.py +++ b/Lib/platform.py @@ -793,7 +793,7 @@ def _follow_symlinks(filepath): filepath = _abspath(filepath) while os.path.islink(filepath): filepath = os.path.normpath( - os.path.join(filepath,os.readlink(filepath))) + os.path.join(os.path.dirname(filepath),os.readlink(filepath))) return filepath def _syscmd_uname(option,default=''):