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

Skip to content

Commit f3335e1

Browse files
committed
Patch inspired by Just van Rossum: on the Mac, in savefilename(), make
the path to save a relative path by prefixing it with os.sep (':'). Also fix an indent inconsistency in the same function.
1 parent c009d19 commit f3335e1

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

Tools/webchecker/websucker.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,9 +95,11 @@ def savefilename(self, url):
9595
host, port = urllib.splitnport(host)
9696
host = string.lower(host)
9797
if not path or path[-1] == "/":
98-
path = path + "index.html"
98+
path = path + "index.html"
9999
if os.sep != "/":
100100
path = string.join(string.split(path, "/"), os.sep)
101+
if os.name == "mac":
102+
path = os.sep + path
101103
path = os.path.join(host, path)
102104
return path
103105

0 commit comments

Comments
 (0)