From e216f303206f269ba89bb4be32ffcb7eb15ca289 Mon Sep 17 00:00:00 2001 From: Florian Forster Date: Wed, 18 Aug 2010 10:21:49 +0200 Subject: [PATCH] collectdctl: Fix problems with strict aliasing. --- src/collectdctl.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/collectdctl.c b/src/collectdctl.c index 53bd6184..60b1e64e 100644 --- a/src/collectdctl.c +++ b/src/collectdctl.c @@ -254,7 +254,7 @@ static int flush (lcc_connection_t *c, int argc, char **argv) } } else if (strcasecmp (key, "plugin") == 0) { - status = array_grow ((void **)&plugins, &plugins_num, + status = array_grow ((void *)&plugins, &plugins_num, sizeof (*plugins)); if (status != 0) BAIL_OUT (status); @@ -262,7 +262,7 @@ static int flush (lcc_connection_t *c, int argc, char **argv) plugins[plugins_num - 1] = value; } else if (strcasecmp (key, "identifier") == 0) { - status = array_grow ((void **)&identifiers, &identifiers_num, + status = array_grow ((void *)&identifiers, &identifiers_num, sizeof (*identifiers)); if (status != 0) BAIL_OUT (status); @@ -280,7 +280,7 @@ static int flush (lcc_connection_t *c, int argc, char **argv) } if (plugins_num == 0) { - status = array_grow ((void **)&plugins, &plugins_num, sizeof (*plugins)); + status = array_grow ((void *)&plugins, &plugins_num, sizeof (*plugins)); if (status != 0) BAIL_OUT (status); -- 2.30.2