/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/branch.py

  • Committer: Martin
  • Date: 2009-09-20 22:12:36 UTC
  • mto: This revision was merged to the branch mainline in revision 5257.
  • Revision ID: gzlist@googlemail.com-20090920221236-84nyjpop0ttgfwzj
Ensure all files opened by bazaar proper are explicitly closed

Show diffs side-by-side

added added

removed removed

Lines of Context:
1439
1439
        """Return the format for the branch object in a_bzrdir."""
1440
1440
        try:
1441
1441
            transport = a_bzrdir.get_branch_transport(None)
1442
 
            format_string = transport.get("format").read()
 
1442
            format_string = transport.get_bytes("format")
1443
1443
            return klass._formats[format_string]
1444
1444
        except errors.NoSuchFile:
1445
1445
            raise errors.NotBranchError(path=transport.base)
1978
1978
    def get_reference(self, a_bzrdir):
1979
1979
        """See BranchFormat.get_reference()."""
1980
1980
        transport = a_bzrdir.get_branch_transport(None)
1981
 
        return transport.get('location').read()
 
1981
        return transport.get_bytes('location')
1982
1982
 
1983
1983
    def set_reference(self, a_bzrdir, to_branch):
1984
1984
        """See BranchFormat.set_reference()."""