summaryrefslogtreecommitdiff
path: root/main/config.c
diff options
context:
space:
mode:
authorCorey Farrell <git@cfware.com>2016-08-19 19:19:28 -0400
committerCorey Farrell <git@cfware.com>2016-08-19 20:16:36 -0400
commit55ccdf93c326ecbfe6a989d45f818fbf7bbe1762 (patch)
treea2240a1eccd9e643995ae0eeba591190d181e2cc /main/config.c
parent8061d9f66f636ada714f719be9809ea58cd5c871 (diff)
Fix checks for allocation debugging.
MALLOC_DEBUG should not be used to check if debugging is actually enabled, __AST_DEBUG_MALLOC should be used instead. MALLOC_DEBUG only indicates that debugging is requested, __AST_DEBUG_MALLOC indicates it is active. Change-Id: I3ce9cdb6ec91b74ee1302941328462231be1ea53
Diffstat (limited to 'main/config.c')
-rw-r--r--main/config.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/main/config.c b/main/config.c
index 599270384..6162149b1 100644
--- a/main/config.c
+++ b/main/config.c
@@ -283,7 +283,7 @@ struct ast_config_include {
static void ast_variable_destroy(struct ast_variable *doomed);
static void ast_includes_destroy(struct ast_config_include *incls);
-#ifdef MALLOC_DEBUG
+#ifdef __AST_DEBUG_MALLOC
struct ast_variable *_ast_variable_new(const char *name, const char *value, const char *filename, const char *file, const char *func, int lineno)
#else
struct ast_variable *ast_variable_new(const char *name, const char *value, const char *filename)
@@ -300,7 +300,7 @@ struct ast_variable *ast_variable_new(const char *name, const char *value, const
}
if (
-#ifdef MALLOC_DEBUG
+#ifdef __AST_DEBUG_MALLOC
(variable = __ast_calloc(1, fn_len + name_len + val_len + sizeof(*variable), file, lineno, func))
#else
(variable = ast_calloc(1, fn_len + name_len + val_len + sizeof(*variable)))