| /** | |
| * This file has no copyright assigned and is placed in the Public Domain. | |
| * This file is part of the mingw-w64 runtime package. | |
| * No warranty is given; refer to the file DISCLAIMER.PD within this package. | |
| */ | |
| #ifndef _INC_WSTDIO_S | |
| #define _INC_WSTDIO_S | |
| #include <corecrt_wstdio.h> | |
| _CRT_BEGIN_C_HEADER | |
| _CRTIMP wchar_t *__cdecl _getws_s(wchar_t *_Str,size_t _SizeInWords); | |
| __DEFINE_CPP_OVERLOAD_SECURE_FUNC_0_0(wchar_t*,_getws_s,wchar_t,_DstBuf) | |
| #ifdef _UCRT | |
| int __cdecl __stdio_common_vswprintf_s(unsigned __int64 _Options, wchar_t *_Str, size_t _Len, const wchar_t *_Format, _locale_t _Locale, va_list _ArgList); | |
| int __cdecl __stdio_common_vsnwprintf_s(unsigned __int64 _Options, wchar_t *_Str, size_t _Len, size_t _MaxCount, const wchar_t *_Format, _locale_t _Locale, va_list _ArgList); | |
| int __cdecl __stdio_common_vfwprintf_s(unsigned __int64 _Options, FILE *_File, const wchar_t *_Format, _locale_t _Locale, va_list _ArgList); | |
| __mingw_ovr int __cdecl _vfwscanf_s_l(FILE *_File, const wchar_t *_Format, _locale_t _Locale, va_list _ArgList) | |
| { | |
| return __stdio_common_vfwscanf(_CRT_INTERNAL_LOCAL_SCANF_OPTIONS | _CRT_INTERNAL_SCANF_SECURECRT, _File, _Format, _Locale, _ArgList); | |
| } | |
| __mingw_ovr int __cdecl vfwscanf_s(FILE* _File, const wchar_t *_Format, va_list _ArgList) | |
| { | |
| return _vfwscanf_s_l(_File, _Format, NULL, _ArgList); | |
| } | |
| __mingw_ovr int __cdecl _vwscanf_s_l(const wchar_t *_Format, _locale_t _Locale, va_list _ArgList) | |
| { | |
| return _vfwscanf_s_l(stdin, _Format, _Locale, _ArgList); | |
| } | |
| __mingw_ovr int __cdecl vwscanf_s(const wchar_t *_Format, va_list _ArgList) | |
| { | |
| return _vfwscanf_s_l(stdin, _Format, NULL, _ArgList); | |
| } | |
| __mingw_ovr int __cdecl _fwscanf_s_l(FILE *_File, const wchar_t *_Format, _locale_t _Locale, ...) | |
| { | |
| __builtin_va_list _ArgList; | |
| int _Ret; | |
| __builtin_va_start(_ArgList, _Locale); | |
| _Ret = _vfwscanf_s_l(_File, _Format, _Locale, _ArgList); | |
| __builtin_va_end(_ArgList); | |
| return _Ret; | |
| } | |
| __mingw_ovr int __cdecl fwscanf_s(FILE *_File, const wchar_t *_Format, ...) | |
| { | |
| __builtin_va_list _ArgList; | |
| int _Ret; | |
| __builtin_va_start(_ArgList, _Format); | |
| _Ret = _vfwscanf_s_l(_File, _Format, NULL, _ArgList); | |
| __builtin_va_end(_ArgList); | |
| return _Ret; | |
| } | |
| __mingw_ovr int __cdecl _wscanf_s_l(const wchar_t *_Format, _locale_t _Locale, ...) | |
| { | |
| __builtin_va_list _ArgList; | |
| int _Ret; | |
| __builtin_va_start(_ArgList, _Locale); | |
| _Ret = _vfwscanf_s_l(stdin, _Format, _Locale, _ArgList); | |
| __builtin_va_end(_ArgList); | |
| return _Ret; | |
| } | |
| __mingw_ovr int __cdecl wscanf_s(const wchar_t *_Format, ...) | |
| { | |
| __builtin_va_list _ArgList; | |
| int _Ret; | |
| __builtin_va_start(_ArgList, _Format); | |
| _Ret = _vfwscanf_s_l(stdin, _Format, NULL, _ArgList); | |
| __builtin_va_end(_ArgList); | |
| return _Ret; | |
| } | |
| __mingw_ovr int __cdecl _vswscanf_s_l(const wchar_t *_Src, const wchar_t *_Format, _locale_t _Locale, va_list _ArgList) | |
| { | |
| return __stdio_common_vswscanf(_CRT_INTERNAL_LOCAL_SCANF_OPTIONS | _CRT_INTERNAL_SCANF_SECURECRT, _Src, (size_t)-1, _Format, _Locale, _ArgList); | |
| } | |
| __mingw_ovr int __cdecl vswscanf_s(const wchar_t *_Src, const wchar_t *_Format, va_list _ArgList) | |
| { | |
| return _vswscanf_s_l(_Src, _Format, NULL, _ArgList); | |
| } | |
| __mingw_ovr int __cdecl _swscanf_s_l(const wchar_t *_Src, const wchar_t *_Format, _locale_t _Locale, ...) | |
| { | |
| __builtin_va_list _ArgList; | |
| int _Ret; | |
| __builtin_va_start(_ArgList, _Locale); | |
| _Ret = _vswscanf_s_l(_Src, _Format, _Locale, _ArgList); | |
| __builtin_va_end(_ArgList); | |
| return _Ret; | |
| } | |
| __mingw_ovr int __cdecl swscanf_s(const wchar_t *_Src, const wchar_t *_Format, ...) | |
| { | |
| __builtin_va_list _ArgList; | |
| int _Ret; | |
| __builtin_va_start(_ArgList, _Format); | |
| _Ret = _vswscanf_s_l(_Src, _Format, NULL, _ArgList); | |
| __builtin_va_end(_ArgList); | |
| return _Ret; | |
| } | |
| __mingw_ovr int __cdecl _vsnwscanf_s_l(const wchar_t *_Src, size_t _MaxCount, const wchar_t *_Format, _locale_t _Locale, va_list _ArgList) | |
| { | |
| return __stdio_common_vswscanf(_CRT_INTERNAL_LOCAL_SCANF_OPTIONS | _CRT_INTERNAL_SCANF_SECURECRT, _Src, _MaxCount, _Format, _Locale, _ArgList); | |
| } | |
| __mingw_ovr int __cdecl _snwscanf_s_l(const wchar_t *_Src, size_t _MaxCount, const wchar_t *_Format, _locale_t _Locale, ...) | |
| { | |
| __builtin_va_list _ArgList; | |
| int _Ret; | |
| __builtin_va_start(_ArgList, _Locale); | |
| _Ret = _vsnwscanf_s_l(_Src, _MaxCount, _Format, _Locale, _ArgList); | |
| __builtin_va_end(_ArgList); | |
| return _Ret; | |
| } | |
| __mingw_ovr int __cdecl _snwscanf_s(const wchar_t *_Src, size_t _MaxCount, const wchar_t *_Format, ...) | |
| { | |
| __builtin_va_list _ArgList; | |
| int _Ret; | |
| __builtin_va_start(_ArgList, _Format); | |
| _Ret = _vsnwscanf_s_l(_Src, _MaxCount, _Format, NULL, _ArgList); | |
| __builtin_va_end(_ArgList); | |
| return _Ret; | |
| } | |
| __mingw_ovr int __cdecl _vfwprintf_s_l(FILE *_File, const wchar_t *_Format, _locale_t _Locale, va_list _ArgList) | |
| { | |
| return __stdio_common_vfwprintf_s(_CRT_INTERNAL_LOCAL_PRINTF_OPTIONS, _File, _Format, _Locale, _ArgList); | |
| } | |
| __mingw_ovr int __cdecl _vwprintf_s_l(const wchar_t *_Format, _locale_t _Locale, va_list _ArgList) | |
| { | |
| return _vfwprintf_s_l(stdout, _Format, _Locale, _ArgList); | |
| } | |
| __mingw_ovr int __cdecl vfwprintf_s(FILE *_File, const wchar_t *_Format, va_list _ArgList) | |
| { | |
| return _vfwprintf_s_l(_File, _Format, NULL, _ArgList); | |
| } | |
| __mingw_ovr int __cdecl vwprintf_s(const wchar_t *_Format, va_list _ArgList) | |
| { | |
| return _vfwprintf_s_l(stdout, _Format, NULL, _ArgList); | |
| } | |
| __mingw_ovr int __cdecl _fwprintf_s_l(FILE *_File, const wchar_t *_Format, _locale_t _Locale, ...) | |
| { | |
| __builtin_va_list _ArgList; | |
| int _Ret; | |
| __builtin_va_start(_ArgList, _Locale); | |
| _Ret = _vfwprintf_s_l(_File, _Format, _Locale, _ArgList); | |
| __builtin_va_end(_ArgList); | |
| return _Ret; | |
| } | |
| __mingw_ovr int __cdecl _wprintf_s_l(const wchar_t *_Format, _locale_t _Locale, ...) | |
| { | |
| __builtin_va_list _ArgList; | |
| int _Ret; | |
| __builtin_va_start(_ArgList, _Locale); | |
| _Ret = _vfwprintf_s_l(stdout, _Format, _Locale, _ArgList); | |
| __builtin_va_end(_ArgList); | |
| return _Ret; | |
| } | |
| __mingw_ovr int __cdecl fwprintf_s(FILE *_File, const wchar_t *_Format, ...) | |
| { | |
| __builtin_va_list _ArgList; | |
| int _Ret; | |
| __builtin_va_start(_ArgList, _Format); | |
| _Ret = _vfwprintf_s_l(_File, _Format, NULL, _ArgList); | |
| __builtin_va_end(_ArgList); | |
| return _Ret; | |
| } | |
| __mingw_ovr int __cdecl wprintf_s(const wchar_t *_Format, ...) | |
| { | |
| __builtin_va_list _ArgList; | |
| int _Ret; | |
| __builtin_va_start(_ArgList, _Format); | |
| _Ret = _vfwprintf_s_l(stdout, _Format, NULL, _ArgList); | |
| __builtin_va_end(_ArgList); | |
| return _Ret; | |
| } | |
| __mingw_ovr int __cdecl _vswprintf_s_l(wchar_t *_DstBuf, size_t _DstSize, const wchar_t *_Format, _locale_t _Locale, va_list _ArgList) | |
| { | |
| return __stdio_common_vswprintf_s(_CRT_INTERNAL_LOCAL_PRINTF_OPTIONS, _DstBuf, _DstSize, _Format, _Locale, _ArgList); | |
| } | |
| __mingw_ovr int __cdecl vswprintf_s(wchar_t *_DstBuf, size_t _DstSize, const wchar_t *_Format, va_list _ArgList) | |
| { | |
| return _vswprintf_s_l(_DstBuf, _DstSize, _Format, NULL, _ArgList); | |
| } | |
| __mingw_ovr int __cdecl _swprintf_s_l(wchar_t *_DstBuf, size_t _DstSize, const wchar_t *_Format, _locale_t _Locale, ...) | |
| { | |
| __builtin_va_list _ArgList; | |
| int _Ret; | |
| __builtin_va_start(_ArgList, _Locale); | |
| _Ret = _vswprintf_s_l(_DstBuf, _DstSize, _Format, _Locale, _ArgList); | |
| __builtin_va_end(_ArgList); | |
| return _Ret; | |
| } | |
| __mingw_ovr int __cdecl swprintf_s(wchar_t *_DstBuf, size_t _DstSize, const wchar_t *_Format, ...) | |
| { | |
| __builtin_va_list _ArgList; | |
| int _Ret; | |
| __builtin_va_start(_ArgList, _Format); | |
| _Ret = _vswprintf_s_l(_DstBuf, _DstSize, _Format, NULL, _ArgList); | |
| __builtin_va_end(_ArgList); | |
| return _Ret; | |
| } | |
| __mingw_ovr int __cdecl _vsnwprintf_s_l(wchar_t *_DstBuf, size_t _DstSize, size_t _MaxCount, const wchar_t *_Format, _locale_t _Locale, va_list _ArgList) | |
| { | |
| return __stdio_common_vsnwprintf_s(_CRT_INTERNAL_LOCAL_PRINTF_OPTIONS, _DstBuf, _DstSize, _MaxCount, _Format, _Locale, _ArgList); | |
| } | |
| __mingw_ovr int __cdecl _vsnwprintf_s(wchar_t *_DstBuf, size_t _DstSize, size_t _MaxCount, const wchar_t *_Format, va_list _ArgList) | |
| { | |
| return _vsnwprintf_s_l(_DstBuf, _DstSize, _MaxCount, _Format, NULL, _ArgList); | |
| } | |
| __mingw_ovr int __cdecl _snwprintf_s_l(wchar_t *_DstBuf, size_t _DstSize, size_t _MaxCount, const wchar_t *_Format, _locale_t _Locale, ...) | |
| { | |
| __builtin_va_list _ArgList; | |
| int _Ret; | |
| __builtin_va_start(_ArgList, _Locale); | |
| _Ret = _vsnwprintf_s_l(_DstBuf, _DstSize, _MaxCount, _Format, _Locale, _ArgList); | |
| __builtin_va_end(_ArgList); | |
| return _Ret; | |
| } | |
| __mingw_ovr int __cdecl _snwprintf_s(wchar_t *_DstBuf, size_t _DstSize, size_t _MaxCount, const wchar_t *_Format, ...) | |
| { | |
| __builtin_va_list _ArgList; | |
| int _Ret; | |
| __builtin_va_start(_ArgList, _Format); | |
| _Ret = _vsnwprintf_s_l(_DstBuf, _DstSize, _MaxCount, _Format, NULL, _ArgList); | |
| __builtin_va_end(_ArgList); | |
| return _Ret; | |
| } | |
| #else /* _UCRT */ | |
| int __cdecl fwprintf_s(FILE *_File,const wchar_t *_Format,...); | |
| int __cdecl wprintf_s(const wchar_t *_Format,...); | |
| int __cdecl vfwprintf_s(FILE *_File,const wchar_t *_Format,va_list _ArgList); | |
| int __cdecl vwprintf_s(const wchar_t *_Format,va_list _ArgList); | |
| int __cdecl vswprintf_s(wchar_t *_Dst,size_t _SizeInWords,const wchar_t *_Format,va_list _ArgList); | |
| int __cdecl swprintf_s(wchar_t *_Dst,size_t _SizeInWords,const wchar_t *_Format,...); | |
| _CRTIMP int __cdecl _vsnwprintf_s(wchar_t *_DstBuf,size_t _DstSizeInWords,size_t _MaxCount,const wchar_t *_Format,va_list _ArgList); | |
| _CRTIMP int __cdecl _snwprintf_s(wchar_t *_DstBuf,size_t _DstSizeInWords,size_t _MaxCount,const wchar_t *_Format,...); | |
| _CRTIMP int __cdecl _wprintf_s_l(const wchar_t *_Format,_locale_t _Locale,...); | |
| _CRTIMP int __cdecl _vwprintf_s_l(const wchar_t *_Format,_locale_t _Locale,va_list _ArgList); | |
| _CRTIMP int __cdecl _fwprintf_s_l(FILE *_File,const wchar_t *_Format,_locale_t _Locale,...); | |
| _CRTIMP int __cdecl _vfwprintf_s_l(FILE *_File,const wchar_t *_Format,_locale_t _Locale,va_list _ArgList); | |
| _CRTIMP int __cdecl _swprintf_s_l(wchar_t *_DstBuf,size_t _DstSize,const wchar_t *_Format,_locale_t _Locale,...); | |
| _CRTIMP int __cdecl _vswprintf_s_l(wchar_t *_DstBuf,size_t _DstSize,const wchar_t *_Format,_locale_t _Locale,va_list _ArgList); | |
| _CRTIMP int __cdecl _snwprintf_s_l(wchar_t *_DstBuf,size_t _DstSize,size_t _MaxCount,const wchar_t *_Format,_locale_t _Locale,...); | |
| _CRTIMP int __cdecl _vsnwprintf_s_l(wchar_t *_DstBuf,size_t _DstSize,size_t _MaxCount,const wchar_t *_Format,_locale_t _Locale,va_list _ArgList); | |
| _CRTIMP int __cdecl _fwscanf_s_l(FILE *_File,const wchar_t *_Format,_locale_t _Locale,...); | |
| _CRTIMP int __cdecl fwscanf_s(FILE *_File, const wchar_t *_Format, ...); | |
| _CRTIMP int __cdecl _swscanf_s_l(const wchar_t *_Src,const wchar_t *_Format,_locale_t _Locale,...); | |
| _CRTIMP int __cdecl swscanf_s(const wchar_t *_Src,const wchar_t *_Format,...); | |
| _CRTIMP int __cdecl _snwscanf_s(const wchar_t *_Src,size_t _MaxCount,const wchar_t *_Format,...); | |
| _CRTIMP int __cdecl _snwscanf_s_l(const wchar_t *_Src,size_t _MaxCount,const wchar_t *_Format,_locale_t _Locale,...); | |
| _CRTIMP int __cdecl _wscanf_s_l(const wchar_t *_Format,_locale_t _Locale,...); | |
| _CRTIMP int __cdecl wscanf_s(const wchar_t *_Format, ...); | |
| #endif /* !_UCRT */ | |
| __DEFINE_CPP_OVERLOAD_SECURE_FUNC_0_2(int, vswprintf_s, wchar_t, _Dst, const wchar_t*, _Format, va_list, _ArgList) | |
| __DEFINE_CPP_OVERLOAD_SECURE_FUNC_0_1_ARGLIST(int,swprintf_s,vswprintf_s,wchar_t,_Dst,const wchar_t*,_Format) | |
| __DEFINE_CPP_OVERLOAD_SECURE_FUNC_0_3(int,_vsnwprintf_s,wchar_t,_DstBuf,size_t,_MaxCount,const wchar_t*,_Format,va_list,_ArgList) | |
| __DEFINE_CPP_OVERLOAD_SECURE_FUNC_0_2_ARGLIST(int,_snwprintf_s,_vsnwprintf_s,wchar_t,_DstBuf,size_t,_MaxCount,const wchar_t*,_Format) | |
| _CRTIMP errno_t __cdecl _wfopen_s(FILE **_File,const wchar_t *_Filename,const wchar_t *_Mode); | |
| _CRTIMP errno_t __cdecl _wfreopen_s(FILE **_File,const wchar_t *_Filename,const wchar_t *_Mode,FILE *_OldFile); | |
| _CRTIMP errno_t __cdecl _wtmpnam_s(wchar_t *_DstBuf,size_t _SizeInWords); | |
| __DEFINE_CPP_OVERLOAD_SECURE_FUNC_0_0(errno_t,_wtmpnam_s,wchar_t,_DstBuf) | |
| _CRT_END_C_HEADER | |
| #endif /* _INC_WSTDIO_S */ |