aboutsummaryrefslogtreecommitdiffstats
path: root/epan
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2005-03-29 16:02:02 +0000
committerGerald Combs <gerald@wireshark.org>2005-03-29 16:02:02 +0000
commit4198c72a69f9060db9137b01683c6430c6717d65 (patch)
tree1c94378770d82336afbb7993b74af34de65e9682 /epan
parent3056b9e17d8eb9e12febd34bcb8521722f77da31 (diff)
Fix a compiler warning.
svn path=/trunk/; revision=13969
Diffstat (limited to 'epan')
-rw-r--r--epan/proto.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/epan/proto.c b/epan/proto.c
index b9535573ed..d5401af98d 100644
--- a/epan/proto.c
+++ b/epan/proto.c
@@ -2128,6 +2128,7 @@ alloc_field_info(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start,
item_length = length_remaining;
}
}
+g_assert(item_length >= 0);
if (item_length < 0) {
REPORT_DISSECTOR_BUG(g_strdup_printf("\"%s\" - \"%s\" invalid length: %d (%s:%u)",
hfinfo->name, hfinfo->abbrev, item_length,
@@ -2364,7 +2365,8 @@ proto_register_protocol(char *name, char *short_name, char *filter_name)
header_field_info *hfinfo;
int proto_id;
char *existing_name;
- gint *key, i;
+ gint *key;
+ guint i;
gboolean found_invalid;
/*