summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 6e18f44)
raw | patch | inline | side by side (parent: 6e18f44)
author | Ruben Kerkhof <ruben@rubenkerkhof.com> | |
Fri, 1 Apr 2016 16:24:23 +0000 (18:24 +0200) | ||
committer | Ruben Kerkhof <ruben@rubenkerkhof.com> | |
Fri, 1 Apr 2016 16:24:23 +0000 (18:24 +0200) |
src/teamspeak2.c | patch | blob | history |
diff --git a/src/teamspeak2.c b/src/teamspeak2.c
index 345f57e0d6a5c534fe57d3a946cd6555e95f9e72..263863b93c8a695e002191fa70cc306d70b30fbb 100644 (file)
--- a/src/teamspeak2.c
+++ b/src/teamspeak2.c
}
/* Allocate memory */
- entry = malloc (sizeof (*entry));
+ entry = calloc (1, sizeof (*entry));
if (entry == NULL)
{
- ERROR ("teamspeak2 plugin: malloc failed.");
+ ERROR ("teamspeak2 plugin: calloc failed.");
return (-1);
}
- memset (entry, 0, sizeof (vserver_list_t));
/* Save data */
entry->port = vserver_port;