dect
/
asterisk
Archived
13
0
Fork 0

use ast_malloc instead of malloc

git-svn-id: http://svn.digium.com/svn/asterisk/trunk@24880 f38db490-d61c-443f-a65b-d21fe96a405b
This commit is contained in:
russell 2006-05-05 16:46:46 +00:00
parent d84eb5f102
commit 06c62d60e9
1 changed files with 2 additions and 2 deletions

View File

@ -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);