[svn-commits] trunk r24880 - /trunk/utils.c

svn-commits at lists.digium.com svn-commits at lists.digium.com
Mon May 8 04:10:51 MST 2006


Author: russell
Date: Fri May  5 11:46:46 2006
New Revision: 24880

URL: http://svn.digium.com/view/asterisk?rev=24880&view=rev
Log:
use ast_malloc instead of malloc

Modified:
    trunk/utils.c

Modified: trunk/utils.c
URL: http://svn.digium.com/view/asterisk/trunk/utils.c?rev=24880&r1=24879&r2=24880&view=diff
==============================================================================
--- trunk/utils.c (original)
+++ trunk/utils.c Fri May  5 11:46:46 2006
@@ -781,7 +781,7 @@
 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 @@
 	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);



More information about the svn-commits mailing list