~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/urlutils.py

  • Committer: Jonathan Riddell
  • Date: 2011-09-07 14:38:26 UTC
  • mfrom: (6123.1.10 +trunk)
  • mto: (6123.1.14 +trunk)
  • mto: This revision was merged to the branch mainline in revision 6124.
  • Revision ID: jriddell@canonical.com-20110907143826-aewhasbrhsq8khyp
mergeĀ inĀ trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
388
388
    """On win32 the drive letter needs to be added to the url base."""
389
389
    # Strip off the drive letter
390
390
    # path is currently /C:/foo
391
 
    if len(path) < 3 or path[2] not in ':|' or path[3] != '/':
 
391
    if len(path) < 4 or path[2] not in ':|' or path[3] != '/':
392
392
        raise errors.InvalidURL(url_base + path,
393
393
            'win32 file:/// paths need a drive letter')
394
394
    url_base += path[0:3] # file:// + /C: