]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
use ast_malloc instead of malloc
authorRussell Bryant <russell@russellbryant.com>
Fri, 5 May 2006 16:46:46 +0000 (16:46 +0000)
committerRussell Bryant <russell@russellbryant.com>
Fri, 5 May 2006 16:46:46 +0000 (16:46 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@24880 65c4cc65-6c06-0410-ace0-fbb531ad65f3

utils.c

diff --git a/utils.c b/utils.c
index 3bd3623d32091b57529f68c3b3b3f1a3d8f94333..807df16b2bc90592a8b4f53ccd7ea0bf58b759ad 100644 (file)
--- a/utils.c
+++ b/utils.c
@@ -781,7 +781,7 @@ size_t strnlen(const char *s, size_t n)
 char *strndup(const char *s, size_t n)
 {
        size_t len = strnlen(s, n);
-       char *new = malloc(len + 1);
+       char *new = ast_malloc(len + 1);
 
        if (!new)
                return NULL;
@@ -802,7 +802,7 @@ int vasprintf(char **strp, const char *fmt, va_list ap)
        va_copy(ap2, ap);
        size = vsnprintf(&s, 1, fmt, ap2);
        va_end(ap2);
-       *strp = malloc(size + 1);
+       *strp = ast_malloc(size + 1);
        if (!*strp)
                return -1;
        vsnprintf(*strp, size + 1, fmt, ap);