PATCH rpc server

Martin Pool mbp at samba.org
Mon Jan 21 19:28:02 GMT 2002


On 22 Jan 2002, Tim Potter <tpot at samba.org> wrote:

> When the structure is unmarshalled and the pointer is zero, set the
> struct foo *bar to NULL.  When marshalling, if struct foo *bar is NULL
> then write out a zero pointer, else write out a one (or 0xdeadbeef
> (-:).

I agree with Tim about removing the ptr_ members, but not about
marshalling them as 0xfeedb0b0.

I wouldn't be surprised the NT unmarshalling code does actually
implement the NDR spec for nonunique pointers: if the same opaque
value is passed for two different pointers then they're meant to be
combined into a pointer to the same object on the server, and the
referent of the pointer is only marshalled once.

So I think it would be equally easy and more reliable for us to send
the bottom 32 bits of the local pointer value.

If it's already been discovered not to do that then I will just blush
and crawl back into my cube. ;-)

-- 
Martin 




More information about the samba-technical mailing list