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;
int status;
int i;
- conf = malloc (sizeof (*conf));
+ conf = calloc (1, sizeof (*conf));
if (conf == NULL)
{
if (conf == NULL)
{
- ERROR ("amqp plugin: malloc failed.");
+ ERROR ("amqp plugin: calloc failed.");
return (ENOMEM);
}
/* Initialize "conf" {{{ */
return (ENOMEM);
}
/* Initialize "conf" {{{ */
- memset (conf, 0, sizeof (*conf));
conf->publish = publish;
conf->name = NULL;
conf->format = CAMQP_FORMAT_COMMAND;
conf->publish = publish;
conf->name = NULL;
conf->format = CAMQP_FORMAT_COMMAND;