From c4fc0b49f05f56174dc904a19d9e4dfc6d3ef523 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Fri, 12 Dec 2008 19:52:06 +0100 Subject: Manually marshall dom_sid, so we can use a fixed size array for dom_sid.sub_auths rather than a dynamically allocated one. This makes it possible to use the same DCE/RPC object code for Samba 3 and Samba 4's DCE/RPC parsers and allows copying sids more easily (since they no longer contain any pointers). The cost of having additional manual marshalling code is limited (~35 additional lines of C code). --- source4/librpc/idl/dom_sid.idl | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'source4/librpc/idl') diff --git a/source4/librpc/idl/dom_sid.idl b/source4/librpc/idl/dom_sid.idl index 1fc8ee2165..40712fc371 100644 --- a/source4/librpc/idl/dom_sid.idl +++ b/source4/librpc/idl/dom_sid.idl @@ -22,13 +22,11 @@ cpp_quote("#define dom_sid0 dom_sid") ] interface dom_sid { - /* a domain SID. Note that unlike Samba3 this contains a pointer, - so you can't copy them using assignment */ - typedef [public,gensize,noprint,nosize] struct { + typedef [public,gensize,noprint,nosize,nopull,nopush] struct { uint8 sid_rev_num; /**< SID revision number */ [range(0,15)] int8 num_auths; /**< Number of sub-authorities */ uint8 id_auth[6]; /**< Identifier Authority */ - uint32 sub_auths[num_auths]; + uint32 sub_auths[15]; } dom_sid; /* id used to identify a endpoint, possibly in a cluster */ @@ -37,6 +35,4 @@ interface dom_sid uint32 id2; uint32 node; } server_id; - } - -- cgit