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-chdlc.c | |
parent | 8d0ea8bc932de5cf57183a593be160515af064d9 (diff) | |
download | wireshark-bced8711f67b5dba76e9d6cdfd1a0246b235df27.tar.gz wireshark-bced8711f67b5dba76e9d6cdfd1a0246b235df27.tar.bz2 wireshark-bced8711f67b5dba76e9d6cdfd1a0246b235df27.zip |
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-chdlc.c')
-rw-r--r-- | packet-chdlc.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/packet-chdlc.c b/packet-chdlc.c index 8017145559..5c66ee6b46 100644 --- a/packet-chdlc.c +++ b/packet-chdlc.c @@ -1,7 +1,7 @@ /* packet-chdlc.c * Routines for Cisco HDLC packet disassembly * - * $Id: packet-chdlc.c,v 1.6 2001/11/26 04:52:49 hagbard Exp $ + * $Id: packet-chdlc.c,v 1.7 2001/12/03 03:59:33 guy Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@ethereal.com> @@ -197,8 +197,11 @@ proto_register_chdlc(void) void proto_reg_handoff_chdlc(void) { + dissector_handle_t chdlc_handle; + data_handle = find_dissector("data"); - dissector_add("wtap_encap", WTAP_ENCAP_CHDLC, dissect_chdlc, proto_chdlc); + chdlc_handle = find_dissector("chdlc"); + dissector_add("wtap_encap", WTAP_ENCAP_CHDLC, chdlc_handle); } #define SLARP_REQUEST 0 @@ -311,5 +314,8 @@ proto_register_slarp(void) void proto_reg_handoff_slarp(void) { - dissector_add("chdlctype", CISCO_SLARP, dissect_slarp, proto_slarp); + dissector_handle_t slarp_handle; + + slarp_handle = create_dissector_handle(dissect_slarp, proto_slarp); + dissector_add("chdlctype", CISCO_SLARP, slarp_handle); } |