summaryrefslogtreecommitdiff
path: root/main
diff options
context:
space:
mode:
Diffstat (limited to 'main')
-rw-r--r--main/logger.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/main/logger.c b/main/logger.c
index fac68d9b6..13f6de890 100644
--- a/main/logger.c
+++ b/main/logger.c
@@ -601,7 +601,7 @@ static int init_logger_chain(const char *altconf)
/* If no config file, we're fine, set default options. */
if (!cfg) {
- if (!(chan = ast_calloc(1, sizeof(*chan)))) {
+ if (!(chan = ast_calloc(1, sizeof(*chan) + 1))) {
fprintf(stderr, "Failed to initialize default logging\n");
return -1;
}