summaryrefslogtreecommitdiff
path: root/usr/src/tools/ctf/cvt/tdata.c
diff options
context:
space:
mode:
authorToomas Soome <tsoome@me.com>2018-05-30 12:38:16 +0300
committerHans Rosenfeld <hans.rosenfeld@joyent.com>2018-06-04 10:35:16 +0200
commitea4ea50f064c5468142b24627acad09a41f060cb (patch)
treeedd308866e93219b4b0973553d9764cc1dfe8c30 /usr/src/tools/ctf/cvt/tdata.c
parenta19d2449c7801a22d6c8370a965dab3d16c77925 (diff)
downloadillumos-gate-ea4ea50f064c5468142b24627acad09a41f060cb.tar.gz
9565 ctf: cast between incompatible function types
Reviewed by: Yuri Pankov <yuripv@yuripv.net> Reviewed by: Andrew Stormont <andyjstormont@gmail.com> Reviewed by: John Levon <john.levon@joyent.com> Approved by: Hans Rosenfeld <rosenfeld@grumpf.hope-2000.org>
Diffstat (limited to 'usr/src/tools/ctf/cvt/tdata.c')
-rw-r--r--usr/src/tools/ctf/cvt/tdata.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/usr/src/tools/ctf/cvt/tdata.c b/usr/src/tools/ctf/cvt/tdata.c
index 295928586e..ca71168bcf 100644
--- a/usr/src/tools/ctf/cvt/tdata.c
+++ b/usr/src/tools/ctf/cvt/tdata.c
@@ -246,22 +246,22 @@ static void (*free_cbs[])(tdesc_t *) = {
};
/*ARGSUSED1*/
-static int
-tdesc_free_cb(tdesc_t *tdp, void *private)
+static void
+tdesc_free_cb(void *ptr, void *private)
{
+ tdesc_t *tdp = ptr;
+
if (tdp->t_name)
free(tdp->t_name);
if (free_cbs[tdp->t_type])
free_cbs[tdp->t_type](tdp);
free(tdp);
-
- return (1);
}
void
tdesc_free(tdesc_t *tdp)
{
- (void) tdesc_free_cb(tdp, NULL);
+ tdesc_free_cb(tdp, NULL);
}
static int
@@ -390,8 +390,8 @@ tdata_new(void)
void
tdata_free(tdata_t *td)
{
- hash_free(td->td_iihash, (void (*)())iidesc_free, NULL);
- hash_free(td->td_layouthash, (void (*)())tdesc_free_cb, NULL);
+ hash_free(td->td_iihash, iidesc_free_cb, NULL);
+ hash_free(td->td_layouthash, tdesc_free_cb, NULL);
hash_free(td->td_idhash, NULL, NULL);
list_free(td->td_fwdlist, NULL, NULL);