=== nbt.idl ================================================================== --- nbt.idl (revision 25057) +++ nbt.idl (revision 25059) @@ -165,12 +165,24 @@ [default] nbt_rdata_data data; } nbt_rdata; +/* + * this macro works arround the problem + * that we need to use nbt_rdata_data + * together with NBT_QTYPE_NETBIOS + * for WACK replies + */ +#define NBT_RES_REC_LEVEL(rr_type, rdata) (\ + (((rr_type) == NBT_QTYPE_NETBIOS) && \ + talloc_check_name(ndr, "struct ndr_push") && \ + ((rdata).data.length == 2)) \ + ? 0 : rr_type) + typedef [flag(LIBNDR_PRINT_ARRAY_HEX)] struct { nbt_name name; nbt_qtype rr_type; nbt_qclass rr_class; uint32 ttl; - [switch_is(rr_type)] nbt_rdata rdata; + [switch_is(NBT_RES_REC_LEVEL(rr_type, rdata))] nbt_rdata rdata; } nbt_res_rec; typedef [flag(NDR_NOALIGN|NDR_BIG_ENDIAN|NDR_PAHEX),public] struct {