From: Ruben Kerkhof Date: Mon, 1 Aug 2016 20:15:25 +0000 (+0200) Subject: apache: no need to zero-initialize X-Git-Tag: collectd-5.6.0~132^2~6 X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=f0c37ceab48cf4b30f5b99ddee988961ba648ef7;p=collectd.git apache: no need to zero-initialize --- diff --git a/src/apache.c b/src/apache.c index 8c24a703..afdeda4e 100644 --- a/src/apache.c +++ b/src/apache.c @@ -240,11 +240,12 @@ static int config_add (oconfig_item_t *ci) if (status == 0) { - user_data_t ud = { 0 }; - char callback_name[3*DATA_MAX_NAME_LEN] = { 0 }; + user_data_t ud = { + .data = st, + .free_func = apache_free + }; - ud.data = st; - ud.free_func = apache_free; + char callback_name[3*DATA_MAX_NAME_LEN]; ssnprintf (callback_name, sizeof (callback_name), "apache/%s/%s",