From: Barry Warsaw Date: Wed, 4 Dec 1996 22:04:39 +0000 (+0000) Subject: Unpacker.get_buffer(): new method to access the internal buffer of data X-Git-Tag: v1.5a1~898 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=75eccc5bcf7773921993a64a9d9e7122183e85ab;p=thirdparty%2FPython%2Fcpython.git Unpacker.get_buffer(): new method to access the internal buffer of data --- diff --git a/Lib/xdrlib.py b/Lib/xdrlib.py index 3c1823312a97..fb1e72da20d9 100644 --- a/Lib/xdrlib.py +++ b/Lib/xdrlib.py @@ -150,6 +150,9 @@ class Unpacker: def set_position(self, position): self.__pos = position + def get_buffer(self): + return self.__buf + def done(self): if self.__pos < len(self.__buf): raise Error('unextracted data remains')