]> git.proxmox.com Git - wasi-libc.git/blob - libc-top-half/musl/src/stdio/snprintf.c
WASI libc prototype implementation.
[wasi-libc.git] / libc-top-half / musl / src / stdio / snprintf.c
1 #include <stdio.h>
2 #include <stdarg.h>
3
4 int snprintf(char *restrict s, size_t n, const char *restrict fmt, ...)
5 {
6 int ret;
7 va_list ap;
8 va_start(ap, fmt);
9 ret = vsnprintf(s, n, fmt, ap);
10 va_end(ap);
11 return ret;
12 }
13