diff options
Diffstat (limited to 'epan/dissectors/packet-netlink.c')
-rw-r--r-- | epan/dissectors/packet-netlink.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/epan/dissectors/packet-netlink.c b/epan/dissectors/packet-netlink.c index b437ed34..200d4718 100644 --- a/epan/dissectors/packet-netlink.c +++ b/epan/dissectors/packet-netlink.c @@ -14,6 +14,8 @@ #include <epan/packet.h> #include <epan/arptypes.h> #include <epan/exceptions.h> +#include <epan/prefs.h> + #include <wiretap/wtap.h> #include <wsutil/ws_roundup.h> @@ -152,6 +154,7 @@ static int * const netlink_header_standard_flags[] = { static int +// NOLINTNEXTLINE(misc-no-recursion) dissect_netlink_attributes_common(tvbuff_t *tvb, int hf_type, int ett_tree, int ett_attrib, void *data, struct packet_netlink_data *nl_data, proto_tree *tree, int offset, int length, netlink_attributes_cb_t cb) { int encoding; @@ -261,6 +264,9 @@ dissect_netlink_attributes_common(tvbuff_t *tvb, int hf_type, int ett_tree, int offset += 2; proto_item_append_text(ti, " %u", rta_type); + // In theory we should use increment_dissection_depth here, but that + // requires adding pinfo all over packet-netlink*.[ch] and we're limited + // to 262144 bytes (WTAP_MAX_PACKET_SIZE_STANDARD). dissect_netlink_attributes(tvb, hf_type, ett_attrib, data, nl_data, attr_tree, offset, rta_len - 4, cb); } @@ -276,6 +282,7 @@ dissect_netlink_attributes_common(tvbuff_t *tvb, int hf_type, int ett_tree, int } int +// NOLINTNEXTLINE(misc-no-recursion) dissect_netlink_attributes(tvbuff_t *tvb, int hf_type, int ett, void *data, struct packet_netlink_data *nl_data, proto_tree *tree, int offset, int length, netlink_attributes_cb_t cb) { return dissect_netlink_attributes_common(tvb, hf_type, ett, -1, data, nl_data, tree, offset, length, cb); |