Fix declaration of index shadows global
Change-Id: I14030ab86c5f3a3fe28b6102f7c0d84494b138e2 Reviewed-on: https://code.wireshark.org/review/1234 Reviewed-by: Evan Huus <eapache@gmail.com>
This commit is contained in:
parent
d47ae54806
commit
38b086152b
10
epan/proto.c
10
epan/proto.c
|
@ -4925,15 +4925,15 @@ header_field_info *
|
|||
proto_get_next_protocol_field(const int proto_id, void **cookie)
|
||||
{
|
||||
protocol_t *protocol = find_protocol_by_id(proto_id);
|
||||
guint index = GPOINTER_TO_INT(*cookie);
|
||||
guint i = GPOINTER_TO_INT(*cookie);
|
||||
|
||||
index++;
|
||||
i++;
|
||||
|
||||
if (index >= protocol->fields->len)
|
||||
if (i >= protocol->fields->len)
|
||||
return NULL;
|
||||
|
||||
*cookie = GINT_TO_POINTER(index);
|
||||
return (header_field_info *)g_ptr_array_index(protocol->fields, index);
|
||||
*cookie = GINT_TO_POINTER(i);
|
||||
return (header_field_info *)g_ptr_array_index(protocol->fields, i);
|
||||
}
|
||||
|
||||
protocol_t *
|
||||
|
|
Loading…
Reference in New Issue