]> git.ipfire.org Git - thirdparty/collectd.git/commitdiff
Initialize metric_family to zero
authorManuel Luis Sanmartín Rozada <manuel.luis@gmail.com>
Sat, 20 Feb 2021 23:01:43 +0000 (00:01 +0100)
committerManuel Luis Sanmartín Rozada <manuel.luis@gmail.com>
Sat, 20 Feb 2021 23:01:43 +0000 (00:01 +0100)
src/protocols.c

index a94bdd5a5e92aece5b6cbee9816080f546fdc675..17f559c885d561e5f4d5b9b907ec4a5f24d63ba5 100644 (file)
@@ -57,7 +57,7 @@ static void submit(const char *protocol_name, const char *str_key,
   ssnprintf(fam_name, sizeof(fam_name), "protocols_%s_%s_total", protocol_name,
             str_key);
 
-  metric_family_t fam;
+  metric_family_t fam = {0};
   fam.type = METRIC_TYPE_COUNTER;
   fam.name = fam_name;