move msghdr and cmsghdr out of bits/socket.h
[musl.git] / src / stdio / vdprintf.c
blobc35d9b4fb0412fdefb2f4a07c198b8de8b451871
1 #include "stdio_impl.h"
3 static size_t wrap_write(FILE *f, const unsigned char *buf, size_t len)
5 return __stdio_write(f, buf, len);
8 int vdprintf(int fd, const char *restrict fmt, va_list ap)
10 FILE f = {
11 .fd = fd, .lbf = EOF, .write = wrap_write,
12 .buf = (void *)fmt, .buf_size = 0,
13 .lock = -1
15 return vfprintf(&f, fmt, ap);