aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-dhcp.c
diff options
context:
space:
mode:
authorMartin Kaiser <wireshark@kaiser.cx>2020-12-16 21:58:15 +0100
committerWireshark GitLab Utility <gerald+gitlab-utility@wireshark.org>2021-01-13 09:45:22 +0000
commit09426b2cd58e19830213220039d5d562057bbdac (patch)
tree9cb26464f3a1a9925c68e233d49f086862e31669 /epan/dissectors/packet-dhcp.c
parenta2b792570858f8fbd14643d72f1ceca76e580768 (diff)
dhcp: remove a variable that is always 0
For dhcp statistics, we only have a single table at index 0.
Diffstat (limited to 'epan/dissectors/packet-dhcp.c')
-rw-r--r--epan/dissectors/packet-dhcp.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/epan/dissectors/packet-dhcp.c b/epan/dissectors/packet-dhcp.c
index 5e6891dde5..4a7b5b1883 100644
--- a/epan/dissectors/packet-dhcp.c
+++ b/epan/dissectors/packet-dhcp.c
@@ -7283,14 +7283,13 @@ dhcp_stat_packet(void *tapdata, packet_info *pinfo _U_, epan_dissect_t *edt _U_,
const char* value = (const char*)data;
stat_tap_table* table;
stat_tap_table_item_type* msg_data;
- guint i = 0;
gint idx;
idx = str_to_val_idx(value, opt53_text);
if (idx < 0)
return TAP_PACKET_DONT_REDRAW;
- table = g_array_index(stat_data->stat_tap_data->tables, stat_tap_table*, i);
+ table = g_array_index(stat_data->stat_tap_data->tables, stat_tap_table*, 0);
msg_data = stat_tap_get_field_data(table, idx, PACKET_COLUMN);
msg_data->value.uint_value++;
stat_tap_set_field_data(table, idx, PACKET_COLUMN, msg_data);