~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/bundle/__init__.py

  • Committer: John Arbash Meinel
  • Date: 2006-06-20 01:04:14 UTC
  • mto: (1711.7.2 win32)
  • mto: This revision was merged to the branch mainline in revision 1796.
  • Revision ID: john@arbash-meinel.com-20060620010414-6046fc4038b56bf0
Workaround was not needed, already solved by using get_transport() and catching PathError

Show diffs side-by-side

added added

removed removed

Lines of Context:
14
14
# along with this program; if not, write to the Free Software
15
15
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
16
16
 
17
 
import errno
18
 
import sys
19
 
 
20
17
import bzrlib.errors as errors
21
18
import bzrlib.urlutils
22
19
import bzrlib.transport
44
41
        return bzrlib.bundle.read_bundle.BundleReader(f)
45
42
    except (errors.TransportError, errors.PathError), e:
46
43
        raise errors.NotABundle(str(e))
47
 
    except (IOError, OSError), e:
48
 
        # On win32 accessing a directory as a file gives EACCES
49
 
        # not ENOENT or EISDIR
50
 
        if sys.platform == 'win32' and e.errno in (errno.EACCES,):
51
 
            raise errors.NotABundle(str(e))
52
 
        raise
 
44