5b01fc1db900aae2e2d701a37331557ff5b1e7a0
[reactos.git] / sdk / lib / crt / printf / _vscwprintf.c
1 /*
2 * COPYRIGHT: GNU GPL, see COPYING in the top level directory
3 * PROJECT: ReactOS crt library
4 * FILE: lib/sdk/crt/printf/_vscwprintf.c
5 * PURPOSE: Implementation of _vscprintf
6 */
7
8 #include <stdio.h>
9 #include <stdarg.h>
10
11 #ifdef _LIBCNT_
12 #include <ntddk.h>
13 #endif
14
15 int __cdecl wstreamout(FILE *stream, const wchar_t *format, va_list argptr);
16
17 int
18 __cdecl
19 _vscwprintf(
20 const wchar_t *format,
21 va_list argptr)
22 {
23 int ret;
24 #ifndef _LIBCNT_
25 FILE nulfile;
26 nulfile._tmpfname = nulfile._ptr = nulfile._base = NULL;
27 nulfile._bufsiz = nulfile._charbuf = nulfile._cnt = 0;
28 nulfile._flag = _IOSTRG | _IOWRT;
29 ret = wstreamout(&nulfile, format, argptr);
30 #else
31 ret = -1;
32 #endif
33 return ret;
34 }