3 #include "oslib/asprintf.h"
5 #ifndef CONFIG_HAVE_VASPRINTF
6 int vasprintf(char **strp, const char *fmt, va_list ap)
15 __va_copy(ap_copy, ap);
17 len = vsnprintf(NULL, 0, fmt, ap_copy);
26 return str ? vsnprintf(str, len, fmt, ap) : -1;
30 #ifndef CONFIG_HAVE_ASPRINTF
31 int asprintf(char **strp, const char *fmt, ...)
37 done = vasprintf(strp, fmt, arg);