summaryrefslogtreecommitdiff
path: root/source3/python
diff options
context:
space:
mode:
authorMartin Pool <mbp@samba.org>2002-11-04 21:56:24 +0000
committerMartin Pool <mbp@samba.org>2002-11-04 21:56:24 +0000
commitfe61a53991f6d4a73207c0d2132c86e6a14ae9b9 (patch)
tree467290962f13d29c8116f7ff48d41edadd29ef9e /source3/python
parentba09904001985cbf9cf1e19956815e5f9e5a810d (diff)
downloadsamba-fe61a53991f6d4a73207c0d2132c86e6a14ae9b9.tar.gz
samba-fe61a53991f6d4a73207c0d2132c86e6a14ae9b9.tar.bz2
samba-fe61a53991f6d4a73207c0d2132c86e6a14ae9b9.zip
pytdbpack_calc_reqd_len: It's no longer an error to supply more data
values than are consumed. (This used to be commit 0c1cfe559877d51090409d67f983a82bbbbaa7e2)
Diffstat (limited to 'source3/python')
-rw-r--r--source3/python/py_tdbpack.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/source3/python/py_tdbpack.c b/source3/python/py_tdbpack.c
index 8478ab28a5..6c697533a0 100644
--- a/source3/python/py_tdbpack.c
+++ b/source3/python/py_tdbpack.c
@@ -307,7 +307,8 @@ pytdbpack_calc_reqd_len(char *format_str,
if (val_i >= val_len) {
PyErr_Format(PyExc_IndexError,
- "samba.tdbpack.pack: value list is too short for format string");
+ "%s: value list is too short for format string",
+ __FUNCTION__);
return -1;
}
@@ -323,13 +324,6 @@ pytdbpack_calc_reqd_len(char *format_str,
len += item_len;
}
- if (val_i != val_len) {
- PyErr_Format(PyExc_IndexError,
- "%s: value list is wrong length for format string",
- __FUNCTION__);
- return -1;
- }
-
return len;
}