Changes in uspace/lib/c/generic/io/asprintf.c [ce52ae70:9d58539] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/generic/io/asprintf.c
rce52ae70 r9d58539 50 50 } 51 51 52 int vprintf_size(const char *fmt, va_list args)53 {54 printf_spec_t ps = {55 asprintf_str_write,56 asprintf_wstr_write,57 NULL58 };59 60 return printf_core(fmt, &ps, args);61 }62 63 int printf_size(const char *fmt, ...)64 {65 va_list args;66 va_start(args, fmt);67 int ret = vprintf_size(fmt, args);68 va_end(args);69 70 return ret;71 }72 73 52 /** Allocate and print to string. 74 53 * … … 82 61 int asprintf(char **strp, const char *fmt, ...) 83 62 { 63 printf_spec_t ps = { 64 asprintf_str_write, 65 asprintf_wstr_write, 66 NULL 67 }; 68 84 69 va_list args; 85 70 va_start(args, fmt); 86 int ret = vprintf_size(fmt, args); 71 72 int ret = printf_core(fmt, &ps, args); 87 73 va_end(args); 88 74
Note:
See TracChangeset
for help on using the changeset viewer.