summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 039aa55)
raw | patch | inline | side by side (parent: 039aa55)
author | Ruben Kerkhof <ruben@rubenkerkhof.com> | |
Mon, 28 Mar 2016 17:32:51 +0000 (19:32 +0200) | ||
committer | Ruben Kerkhof <ruben@rubenkerkhof.com> | |
Mon, 28 Mar 2016 17:32:51 +0000 (19:32 +0200) |
src/amqp.c | patch | blob | history |
diff --git a/src/amqp.c b/src/amqp.c
index 4206bdc1e3ee36b99192452b377943e007fb8af8..ec7943022b8db23177dae9e284e5a5fe6717abcf 100644 (file)
--- a/src/amqp.c
+++ b/src/amqp.c
int status;
int i;
- conf = malloc (sizeof (*conf));
+ conf = calloc (1, sizeof (*conf));
if (conf == NULL)
{
- ERROR ("amqp plugin: malloc failed.");
+ ERROR ("amqp plugin: calloc failed.");
return (ENOMEM);
}
/* Initialize "conf" {{{ */
- memset (conf, 0, sizeof (*conf));
conf->publish = publish;
conf->name = NULL;
conf->format = CAMQP_FORMAT_COMMAND;