Show More
@@ -161,10 +161,13 b" protomap = {'http': httpcheck," | |||
|
161 | 161 | 'file': filecheck, |
|
162 | 162 | } |
|
163 | 163 | def issvnurl(url): |
|
164 | if not '://' in url: | |
|
165 | return False | |
|
164 | try: | |
|
166 | 165 | proto, path = url.split('://', 1) |
|
167 |
path = urllib.url2pathname(path) |
|
|
166 | path = urllib.url2pathname(path) | |
|
167 | except ValueError: | |
|
168 | proto = 'file' | |
|
169 | path = os.path.abspath(url) | |
|
170 | path = path.replace(os.sep, '/') | |
|
168 | 171 | check = protomap.get(proto, lambda p, p2: False) |
|
169 | 172 | while '/' in path: |
|
170 | 173 | if check(path, proto): |
General Comments 0
You need to be logged in to leave comments.
Login now