aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-netlink.h
diff options
context:
space:
mode:
authorPeter Wu <peter@lekensteyn.nl>2017-04-17 00:54:32 +0200
committerMichael Mann <mmann78@netscape.net>2017-04-17 02:06:56 +0000
commit61c5e8e76d215cd0f1ea2139ecafbada1f933973 (patch)
treea9961f61e8e6a91278252df9c65f38111b6347f8 /epan/dissectors/packet-netlink.h
parent407a2b07e55a262905881c7d1e225d618e9824fb (diff)
genl: make subdissectors responsible for header
Allow subdissectors to specify the command field for the Generic Netlink message header, similar to how Netlink subdissectors handle the Netlink message header (for its type field). Pass the root tree instead of the genl tree to subdissectors (so subdissectors can add their own layer). Change-Id: I3e56f538661b7e8a51d2411da14d181ead820c4b Reviewed-on: https://code.wireshark.org/review/21150 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Reviewed-by: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan/dissectors/packet-netlink.h')
-rw-r--r--epan/dissectors/packet-netlink.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/epan/dissectors/packet-netlink.h b/epan/dissectors/packet-netlink.h
index 12b872e2e7..07e52e9523 100644
--- a/epan/dissectors/packet-netlink.h
+++ b/epan/dissectors/packet-netlink.h
@@ -135,9 +135,13 @@ typedef struct {
struct packet_netlink_data *data;
int encoding; /* copy of data->encoding */
+ /* For internal use by genl. */
+ proto_tree *genl_tree;
+
/* fields from genlmsghdr */
guint8 cmd; /* Command number */
- proto_item *cmd_pi; /* Field for command, for appending protocol-specific name. */
} genl_info_t;
+int dissect_genl_header(tvbuff_t *tvb, genl_info_t *genl_info, header_field_info *hfi_cmd);
+
#endif /* __PACKET_NETLINK_H__ */