~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/_bencode_py.py

  • Committer: John Arbash Meinel
  • Date: 2009-06-03 01:37:27 UTC
  • mfrom: (2694.5.22 bencode-pyrex)
  • mto: This revision was merged to the branch mainline in revision 4410.
  • Revision ID: john@arbash-meinel.com-20090603013727-wtxochxrd0zqf1vg
Merge the bencode implementation.

Show diffs side-by-side

added added

removed removed

Lines of Context:
86
86
        return (r, f + 1)
87
87
 
88
88
    def bdecode(self, x):
 
89
        if type(x) != str:
 
90
            raise TypeError
89
91
        try:
90
92
            r, l = self.decode_func[x[0]](x, 0)
91
93
        except (IndexError, KeyError):