Add svn:// protocol support to svn_util.py.

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@459 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
Marshall Greenblatt 2012-01-05 19:47:45 +00:00
parent 6cf84686a5
commit 8dc8c273f6
1 changed files with 2 additions and 1 deletions

View File

@ -3,13 +3,14 @@
# can be found in the LICENSE file.
import os
import sys
import urllib
def check_url(url):
""" Check the URL and raise an exception if invalid. """
if ':' in url[:7]:
parts = url.split(':', 1)
if (parts[0] == 'http' or parts[0] == 'https') and \
if (parts[0] == 'http' or parts[0] == 'https' or parts[0] == 'svn') and \
parts[1] == urllib.quote(parts[1]):
return url
sys.stderr.write('Invalid URL: '+url+"\n")