Richard,
Here is a quick hack that should fix the problem.
You must change the dissect_dns declaration from static.
Then in dissect_nbns after the local variable declarations
extern void dissect_dns( const u_char *pd, int offset, frame_data *fd,
proto_tree *tree);
/* Hack to make sure we do DNS not WINS when needed */
if (( pi.srcport == 53) || (pi.destport == 53)){
dissect_dns( pd, offset, fd, tree);
return;
}
A little cleaner hack, that doesn't need to change the dns declaration
extern void decode_udp_ports( const u_char *pd, int offset, frame_data *fd,
proto_tree *tree, int uh_sport, int uh_dport);
if (( pi.srcport == 53) || (pi.destport == 53)){
decode_udp_ports( pd, offset, fd, tree, 53, 53);
return;
}
You can include the packet-udp.h file to avoid the decode_upd_ports
declaration.
Personally I prefer the second method.
We wouldn't have to do this if we could get the address of dissect_dns
per this email from Andreas Sikkema -
> If only you could call an Ethereal basic function which returns the
address
> of the protocol dissector from a plugin, f.i.:
> dissector_q931 = get_dissector_address("Q.931");
Jeff Foster
jfoste@xxxxxxxxxxxx