aboutsummaryrefslogtreecommitdiffstats
path: root/epan/proto.c
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2015-12-28 13:00:39 -0800
committerGuy Harris <guy@alum.mit.edu>2015-12-28 22:24:56 +0000
commitbc13e834cc681c6a01a39d25b125a23950139296 (patch)
tree784012e8930307518340cfd26597d776e1974657 /epan/proto.c
parentc2b774326471f03c81a23466aac9308f931f865e (diff)
Don't cast away constness for the key in g_hash_table_lookup().
Change-Id: Ibd5cf8947028d90a734de629e3c4202af9d0514b Reviewed-on: https://code.wireshark.org/review/12887 Petri-Dish: Guy Harris <guy@alum.mit.edu> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'epan/proto.c')
-rw-r--r--epan/proto.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/epan/proto.c b/epan/proto.c
index 783af76eea..396eac480d 100644
--- a/epan/proto.c
+++ b/epan/proto.c
@@ -5321,7 +5321,7 @@ proto_register_protocol(const char *name, const char *short_name,
}
g_hash_table_insert(proto_names, key, (gpointer)name);
- existing_protocol = (const protocol_t *)g_hash_table_lookup(proto_short_names, (gpointer)short_name);
+ existing_protocol = (const protocol_t *)g_hash_table_lookup(proto_short_names, short_name);
if (existing_protocol != NULL) {
g_error("Duplicate protocol short_name \"%s\"!"
" This might be caused by an inappropriate plugin or a development error.", short_name);
@@ -5339,7 +5339,7 @@ proto_register_protocol(const char *name, const char *short_name,
" Allowed are lower characters, digits, '-', '_' and '.'."
" This might be caused by an inappropriate plugin or a development error.", filter_name);
}
- existing_protocol = (const protocol_t *)g_hash_table_lookup(proto_filter_names, (gpointer)filter_name);
+ existing_protocol = (const protocol_t *)g_hash_table_lookup(proto_filter_names, filter_name);
if (existing_protocol != NULL) {
g_error("Duplicate protocol filter_name \"%s\"!"
" This might be caused by an inappropriate plugin or a development error.", filter_name);
@@ -5533,7 +5533,7 @@ proto_get_id_by_filter_name(const gchar *filter_name)
DISSECTOR_ASSERT_HINT(filter_name, "No filter name present");
- protocol = (const protocol_t *)g_hash_table_lookup(proto_filter_names, (gpointer)filter_name);
+ protocol = (const protocol_t *)g_hash_table_lookup(proto_filter_names, filter_name);
if (protocol == NULL)
return -1;
@@ -5547,7 +5547,7 @@ proto_get_id_by_short_name(const gchar *short_name)
DISSECTOR_ASSERT_HINT(short_name, "No short name present");
- protocol = (const protocol_t *)g_hash_table_lookup(proto_short_names, (gpointer)short_name);
+ protocol = (const protocol_t *)g_hash_table_lookup(proto_short_names, short_name);
if (protocol == NULL)
return -1;