summaryrefslogtreecommitdiff
path: root/source4/scripting/python
diff options
context:
space:
mode:
Diffstat (limited to 'source4/scripting/python')
-rw-r--r--source4/scripting/python/samba/ndr.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/source4/scripting/python/samba/ndr.py b/source4/scripting/python/samba/ndr.py
index ccab1123d9..39e4a482ef 100644
--- a/source4/scripting/python/samba/ndr.py
+++ b/source4/scripting/python/samba/ndr.py
@@ -33,15 +33,16 @@ def ndr_pack(object):
return ndr_pack()
-def ndr_unpack(cls, data):
+def ndr_unpack(cls, data, allow_remaining=False):
"""NDR unpack an object.
:param cls: Class of the object to unpack
:param data: Buffer to unpack
+ :param allow_remaining: allows remaining data at the end (default=False)
:return: Unpacked object
"""
object = cls()
- object.__ndr_unpack__(data)
+ object.__ndr_unpack__(data, allow_remaining=allow_remaining)
return object