summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2009-12-14 15:33:32 +0100
committerStefan Metzmacher <metze@samba.org>2010-02-18 13:44:03 +0100
commit05347754ee61f06466d6d9b7f390001992f793ce (patch)
tree46a9e6d80b9f8750e83708f2390a150ba2dc6edf
parentb5f9c44da55abb28222441a7e064a2a25891981f (diff)
downloadsamba-05347754ee61f06466d6d9b7f390001992f793ce.tar.gz
samba-05347754ee61f06466d6d9b7f390001992f793ce.tar.bz2
samba-05347754ee61f06466d6d9b7f390001992f793ce.zip
libndr: store a subcontext buffer size in ndr_push_subcontext_start.
Guenther
-rw-r--r--librpc/ndr/libndr.h1
-rw-r--r--librpc/ndr/ndr.c1
2 files changed, 2 insertions, 0 deletions
diff --git a/librpc/ndr/libndr.h b/librpc/ndr/libndr.h
index 124c5f0d6e..41e214da2a 100644
--- a/librpc/ndr/libndr.h
+++ b/librpc/ndr/libndr.h
@@ -86,6 +86,7 @@ struct ndr_push {
uint32_t offset;
uint32_t relative_base_offset;
+ uint32_t relative_end_offset;
struct ndr_token_list *relative_base_list;
struct ndr_token_list *switch_list;
diff --git a/librpc/ndr/ndr.c b/librpc/ndr/ndr.c
index 0ff43c3eb4..e78b7ee94a 100644
--- a/librpc/ndr/ndr.c
+++ b/librpc/ndr/ndr.c
@@ -596,6 +596,7 @@ _PUBLIC_ enum ndr_err_code ndr_push_subcontext_start(struct ndr_push *ndr,
if (size_is > 0) {
NDR_CHECK(ndr_push_zero(subndr, size_is));
subndr->offset = 0;
+ subndr->relative_end_offset = size_is;
}
*_subndr = subndr;