* Routines for Registration Response Message dissection
* Copyright 2002, Anand V. Narwani <anand[AT]narwani.org>
*
- * $Id: packet-regrsp.c,v 1.7 2003/12/13 03:18:38 guy Exp $
+ * $Id$
*
- * Ethereal - Network traffic analyzer
- * By Gerald Combs <gerald@ethereal.com>
+ * Wireshark - Network traffic analyzer
+ * By Gerald Combs <gerald@wireshark.org>
* Copyright 1998 Gerald Combs
*
* This program is free software; you can redistribute it and/or
# include "config.h"
#endif
-#include "plugins/plugin_api.h"
-#include "plugins/plugin_api_defs.h"
-#include "moduleinfo.h"
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-#include <gmodule.h>
-
#include <epan/packet.h>
/* Initialize the protocol and registered fields */
{
proto_item *it;
- proto_tree *regrsp_tree;
+ proto_tree *regrsp_tree = NULL;
guint16 sid;
guint8 response;
tvbuff_t *next_tvb;
FALSE);
proto_tree_add_item (regrsp_tree, hf_docsis_regrsp_response, tvb, 2, 1,
FALSE);
- /* Call Dissector for Appendix C TLV's */
- next_tvb = tvb_new_subset (tvb, 3, -1, -1);
- call_dissector (docsis_tlv_handle, next_tvb, pinfo, regrsp_tree);
}
+ /* Call Dissector for Appendix C TLV's */
+ next_tvb = tvb_new_subset_remaining (tvb, 3);
+ call_dissector (docsis_tlv_handle, next_tvb, pinfo, regrsp_tree);
}
-/* Register the protocol with Ethereal */
+/* Register the protocol with Wireshark */
/* this format is require because a script is used to build the C function
that calls all the protocol registration.
/* Setup list of header fields See Section 1.6.1 for details*/
static hf_register_info hf[] = {
{&hf_docsis_regrsp,
- {"Registration Response", "docsis.regrsp",
- FT_BYTES, BASE_HEX, NULL, 0x0,
+ {"Registration Response", "docsis_regrsp",
+ FT_BYTES, BASE_NONE, NULL, 0x0,
"Registration Request", HFILL}
},
{&hf_docsis_regrsp_sid,
- {"Service Identifier", "docsis.regrsp.sid",
+ {"Service Identifier", "docsis_regrsp.sid",
FT_UINT16, BASE_DEC, NULL, 0x0,
- "Service Identifier", HFILL}
+ NULL, HFILL}
},
{&hf_docsis_regrsp_response,
- {"Response Code", "docsis.regrsp.respnse",
+ {"Response Code", "docsis_regrsp.respnse",
FT_UINT8, BASE_DEC, VALS (docsis_conf_code), 0x0,
- "Response Code", HFILL}
+ NULL, HFILL}
},
};