diff options
author | Guy Harris <guy@alum.mit.edu> | 2001-12-03 04:00:26 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2001-12-03 04:00:26 +0000 |
commit | bced8711f67b5dba76e9d6cdfd1a0246b235df27 (patch) | |
tree | 6303e298a7b136a1e1da306950398c99e3e71432 /packet-nbns.c | |
parent | 8d0ea8bc932de5cf57183a593be160515af064d9 (diff) |
Make "dissector_add()", "dissector_delete()", and "dissector_change()"
take a dissector handle as an argument, rather than a pointer to a
dissector function and a protocol ID. Associate dissector handles with
dissector table entries.
svn path=/trunk/; revision=4308
Diffstat (limited to 'packet-nbns.c')
-rw-r--r-- | packet-nbns.c | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/packet-nbns.c b/packet-nbns.c index 1c7647b74a..b64d3bc3cc 100644 --- a/packet-nbns.c +++ b/packet-nbns.c @@ -3,7 +3,7 @@ * to when it had only NBNS) * Guy Harris <guy@alum.mit.edu> * - * $Id: packet-nbns.c,v 1.65 2001/11/21 02:01:05 guy Exp $ + * $Id: packet-nbns.c,v 1.66 2001/12/03 03:59:37 guy Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@ethereal.com> @@ -1807,8 +1807,13 @@ proto_register_nbt(void) void proto_reg_handoff_nbt(void) { - dissector_add("udp.port", UDP_PORT_NBNS, dissect_nbns, proto_nbns); - dissector_add("udp.port", UDP_PORT_NBDGM, dissect_nbdgm, proto_nbdgm); - dissector_add("tcp.port", TCP_PORT_NBSS, dissect_nbss, proto_nbss); - dissector_add("tcp.port", TCP_PORT_CIFS, dissect_nbss, proto_nbss); + dissector_handle_t nbns_handle, nbdgm_handle, nbss_handle; + + nbns_handle = create_dissector_handle(dissect_nbns, proto_nbns); + dissector_add("udp.port", UDP_PORT_NBNS, nbns_handle); + nbdgm_handle = create_dissector_handle(dissect_nbdgm, proto_nbdgm); + dissector_add("udp.port", UDP_PORT_NBDGM, nbdgm_handle); + nbss_handle = create_dissector_handle(dissect_nbss, proto_nbss); + dissector_add("tcp.port", TCP_PORT_NBSS, nbss_handle); + dissector_add("tcp.port", TCP_PORT_CIFS, nbss_handle); } |