IDL variable sized array of arrays problem
Jelmer Vernooij
jelmer at samba.org
Mon Jan 14 12:14:50 GMT 2008
Am Montag, den 14.01.2008, 11:46 +0000 schrieb Amin Azez:
> This may be an IDL bug or a misunderstanding in my own mind. It's not
> holding me up, but I thought I'd mention it for interest:
>
> This IDL:
>
> void proxy_Read(
> [in] uint32 fnum, /* file number as supplied by remote device */
> [in] uint32 offset,
> [in] uint32 mincnt,
> [in] uint32 maxcnt,
> [in,out,ref] uint16 *flags, /* read_for_execute, zlib, md5 etc */
> [in] uint16 digest_count,
> [in] [size_is(digest_count)] uint[8] digest[16][],
> [out] uint32 *nread,
> [out] [size_is(*nread)] uint8 data[]
> );
>
> fails on:
> [in] [size_is(digest_count)] uint[8] digest[16][],
> with:
> Compiling librpc/gen_ndr/ndr_proxy.c
> librpc/gen_ndr/ndr_proxy.c: In function ‘ndr_pull_proxy_Read’:
> librpc/gen_ndr/ndr_proxy.c:61: error: cast specifies array type
>
> line 61 says:
> NDR_PULL_ALLOC_N(ndr, r->in.digest, ndr_get_array_size(ndr,
> &r->in.digest[cntr_digest_0]));
>
> (admittedly that array structure was not a ideal, I was just getting
> something working):
Pidl doesn't support multi-dimension arrays properly yet. AFAIK midl
doesn't support it either and only supports arrays of strings.
Cheers,
Jelmer
--
Jelmer Vernooij <jelmer at samba.org> - http://samba.org/~jelmer/
Jabber: jelmer at jabber.fsfe.org
More information about the samba-technical
mailing list