From: Florian Forster Date: Sun, 3 Feb 2013 09:46:06 +0000 (+0100) Subject: postgresql plugin: Fix cast (was breaking aliasing rules). X-Git-Tag: collectd-5.2.2~14 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=7b98c5c1b92be4a64874d7bd0303912ee6edd918;p=collectd.git postgresql plugin: Fix cast (was breaking aliasing rules). postgresql.c: In function 'c_psql_flush': postgresql.c:974: warning: dereferencing type-punned pointer will break strict-aliasing rules --- diff --git a/src/postgresql.c b/src/postgresql.c index e7b247e7..98ceb6d3 100644 --- a/src/postgresql.c +++ b/src/postgresql.c @@ -971,7 +971,7 @@ static int c_psql_flush (cdtime_t timeout, size_t i; if ((ud != NULL) && (ud->data != NULL)) { - dbs = (c_psql_database_t **)&ud->data; + dbs = (void *)&ud->data; dbs_num = 1; }