summaryrefslogtreecommitdiff
path: root/epan/uat.c
diff options
context:
space:
mode:
authorJoão Valverde <joao.valverde@tecnico.ulisboa.pt>2015-12-30 07:45:35 +0000
committerGuy Harris <guy@alum.mit.edu>2015-12-31 22:56:34 +0000
commit146c4b701696cb54e9e5ad4668e3ad88743c546e (patch)
treebcf117678f9def35304e63d0843dc46889199962 /epan/uat.c
parentc14df7f7a80b3650eff08e46c9fbfbd522b435dc (diff)
downloadwireshark-146c4b701696cb54e9e5ad4668e3ad88743c546e.tar.gz
uat: Fix warnings [-Wcast-qual]
uat_fld_tostr_cb_t callback *out_ptr argument is g_mallocated and is to be freed by the caller so drop constness requirement to fix the corresponding g_free warnings. Change-Id: I1be25fa3e2f54fb32058ac0b5c1631b193b07701 Reviewed-on: https://code.wireshark.org/review/12943 Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'epan/uat.c')
-rw-r--r--epan/uat.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/epan/uat.c b/epan/uat.c
index 0301d0cde5..c0a4570a12 100644
--- a/epan/uat.c
+++ b/epan/uat.c
@@ -250,7 +250,7 @@ uat_t* uat_get_table_by_name(const char* name) {
static void putfld(FILE* fp, void* rec, uat_field_t* f) {
guint fld_len;
- const char* fld_ptr;
+ char* fld_ptr;
f->cb.tostr(rec,&fld_ptr,&fld_len,f->cbdata.tostr,f->fld_data);
@@ -290,7 +290,7 @@ static void putfld(FILE* fp, void* rec, uat_field_t* f) {
g_assert_not_reached();
}
- g_free((char*)fld_ptr);
+ g_free(fld_ptr);
}
gboolean uat_save(uat_t* uat, char** error) {