summaryrefslogtreecommitdiffstats
path: root/Lib/site.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/site.py')
-rw-r--r--Lib/site.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/Lib/site.py b/Lib/site.py
index 12fe71d..807ebc7 100644
--- a/Lib/site.py
+++ b/Lib/site.py
@@ -59,6 +59,12 @@ ImportError exception, it is silently ignored.
import sys, os
+if os.sep==".":
+ endsep = "/"
+else:
+ endsep = "."
+
+
def makepath(*paths):
dir = os.path.join(*paths)
return os.path.normcase(os.path.abspath(dir))
@@ -99,7 +105,7 @@ def addsitedir(sitedir):
names = map(os.path.normcase, names)
names.sort()
for name in names:
- if name[-4:] == ".pth":
+ if name[-4:] == endsep + "pth":
addpackage(sitedir, name)
def addpackage(sitedir, name):