From 63a6a077da4d1e6d4ec3c48b0d3bacccdbc958f2 Mon Sep 17 00:00:00 2001 From: kpfleming Date: Fri, 15 Jul 2005 22:06:15 +0000 Subject: phase two of string portability stuff: don't need ast_ prefixes on functions use individual #defines for function presence add vasprintf to portability library git-svn-id: http://svn.digium.com/svn/asterisk/trunk@6143 f38db490-d61c-443f-a65b-d21fe96a405b --- cli.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'cli.c') diff --git a/cli.c b/cli.c index af77b5af5..f539cb33a 100755 --- a/cli.c +++ b/cli.c @@ -47,15 +47,10 @@ void ast_cli(int fd, char *fmt, ...) { char *stuff; int res = 0; - va_list ap; + va_start(ap, fmt); -#ifdef SOLARIS - stuff = (char *)malloc(10240); - vsnprintf(stuff, 10240, fmt, ap); -#else res = vasprintf(&stuff, fmt, ap); -#endif va_end(ap); if (res == -1) { ast_log(LOG_ERROR, "Out of memory\n"); -- cgit v1.2.3