msvcrt: Add _vscprintf_p implementation.

This commit is contained in:
Piotr Caban 2015-01-20 13:43:09 +01:00 committed by Alexandre Julliard
parent 57582b37b3
commit bd1428ef50
8 changed files with 49 additions and 13 deletions

View File

@ -1446,8 +1446,8 @@
@ stub _vprintf_s_l
@ cdecl _vscprintf(str ptr) MSVCRT__vscprintf
@ stub _vscprintf_l
@ stub _vscprintf_p
@ stub _vscprintf_p_l
@ cdecl _vscprintf_p(str ptr) MSVCRT__vscprintf_p
@ cdecl _vscprintf_p_l(str ptr ptr) MSVCRT__vscprintf_p_l
@ cdecl _vscwprintf(wstr ptr) MSVCRT__vscwprintf
@ cdecl _vscwprintf_l(wstr ptr ptr) MSVCRT__vscwprintf_l
@ cdecl _vscwprintf_p(wstr ptr) MSVCRT__vscwprintf_p

View File

@ -1804,8 +1804,8 @@
@ stub _vprintf_s_l
@ cdecl _vscprintf(str ptr) MSVCRT__vscprintf
@ stub _vscprintf_l
@ stub _vscprintf_p
@ stub _vscprintf_p_l
@ cdecl _vscprintf_p(str ptr) MSVCRT__vscprintf_p
@ cdecl _vscprintf_p_l(str ptr ptr) MSVCRT__vscprintf_p_l
@ cdecl _vscwprintf(wstr ptr) MSVCRT__vscwprintf
@ cdecl _vscwprintf_l(wstr ptr ptr) MSVCRT__vscwprintf_l
@ cdecl _vscwprintf_p(wstr ptr) MSVCRT__vscwprintf_p

View File

@ -1819,8 +1819,8 @@
@ stub _vprintf_s_l
@ cdecl _vscprintf(str ptr) MSVCRT__vscprintf
@ stub _vscprintf_l
@ stub _vscprintf_p
@ stub _vscprintf_p_l
@ cdecl _vscprintf_p(str ptr) MSVCRT__vscprintf_p
@ cdecl _vscprintf_p_l(str ptr ptr) MSVCRT__vscprintf_p_l
@ cdecl _vscwprintf(wstr ptr) MSVCRT__vscwprintf
@ cdecl _vscwprintf_l(wstr ptr ptr) MSVCRT__vscwprintf_l
@ cdecl _vscwprintf_p(wstr ptr) MSVCRT__vscwprintf_p

View File

@ -1516,8 +1516,8 @@
@ stub _vprintf_s_l
@ cdecl _vscprintf(str ptr) msvcr120._vscprintf
@ stub _vscprintf_l
@ stub _vscprintf_p
@ stub _vscprintf_p_l
@ cdecl _vscprintf_p(str ptr) msvcr120._vscprintf_p
@ cdecl _vscprintf_p_l(str ptr ptr) msvcr120._vscprintf_p_l
@ cdecl _vscwprintf(wstr ptr) msvcr120._vscwprintf
@ cdecl _vscwprintf_l(wstr ptr ptr) msvcr120._vscwprintf_l
@ cdecl _vscwprintf_p(wstr ptr) msvcr120._vscwprintf_p

View File

@ -1126,8 +1126,8 @@
@ stub _vprintf_s_l
@ cdecl _vscprintf(str ptr) MSVCRT__vscprintf
@ stub _vscprintf_l
@ stub _vscprintf_p
@ stub _vscprintf_p_l
@ cdecl _vscprintf_p(str ptr) MSVCRT__vscprintf_p
@ cdecl _vscprintf_p_l(str ptr ptr) MSVCRT__vscprintf_p_l
@ cdecl _vscwprintf(wstr ptr) MSVCRT__vscwprintf
@ cdecl _vscwprintf_l(wstr ptr ptr) MSVCRT__vscwprintf_l
@ cdecl _vscwprintf_p(wstr ptr) MSVCRT__vscwprintf_p

View File

@ -1101,8 +1101,8 @@
@ stub _vprintf_s_l
@ cdecl _vscprintf(str ptr) MSVCRT__vscprintf
@ stub _vscprintf_l
@ stub _vscprintf_p
@ stub _vscprintf_p_l
@ cdecl _vscprintf_p(str ptr) MSVCRT__vscprintf_p
@ cdecl _vscprintf_p_l(str ptr ptr) MSVCRT__vscprintf_p_l
@ cdecl _vscwprintf(wstr ptr) MSVCRT__vscwprintf
@ cdecl _vscwprintf_l(wstr ptr ptr) MSVCRT__vscwprintf_l
@ cdecl _vscwprintf_p(wstr ptr) MSVCRT__vscwprintf_p

View File

@ -1059,7 +1059,7 @@
@ cdecl _utime(str ptr)
@ cdecl _vscprintf(str ptr) MSVCRT__vscprintf
# stub _vscprintf_l(str ptr ptr)
# stub _vscprintf_p_l(str ptr ptr)
@ cdecl _vscprintf_p_l(str ptr ptr) MSVCRT__vscprintf_p_l
@ cdecl _vscwprintf(wstr ptr) MSVCRT__vscwprintf
@ cdecl _vscwprintf_l(wstr ptr ptr) MSVCRT__vscwprintf_l
@ cdecl _vscwprintf_p_l(wstr ptr ptr) MSVCRT__vscwprintf_p_l

View File

@ -824,6 +824,42 @@ int CDECL MSVCRT__vscprintf( const char *format, __ms_va_list valist )
return MSVCRT_vsnprintf( NULL, INT_MAX, format, valist );
}
/*********************************************************************
* _vscprintf_p_l (MSVCRT.@)
*/
int CDECL MSVCRT__vscprintf_p_l(const char *format,
MSVCRT__locale_t locale, __ms_va_list args)
{
printf_arg args_ctx[MSVCRT__ARGMAX+1];
struct _str_ctx_a puts_ctx = {INT_MAX, NULL};
int ret;
memset(args_ctx, 0, sizeof(args_ctx));
ret = create_positional_ctx_a(args_ctx, format, args);
if(ret < 0) {
MSVCRT__invalid_parameter(NULL, NULL, NULL, 0, 0);
*MSVCRT__errno() = MSVCRT_EINVAL;
return ret;
} else if(ret == 0) {
ret = pf_printf_a(puts_clbk_str_a, &puts_ctx, format, locale, FALSE, TRUE,
arg_clbk_valist, NULL, &args);
} else {
ret = pf_printf_a(puts_clbk_str_a, &puts_ctx, format, locale, TRUE, TRUE,
arg_clbk_positional, args_ctx, NULL);
}
return ret;
}
/*********************************************************************
* _vscprintf_p (MSVCR80.@)
*/
int CDECL MSVCRT__vscprintf_p(const char *format, __ms_va_list argptr)
{
return MSVCRT__vscprintf_p_l(format, NULL, argptr);
}
/*********************************************************************
* _snprintf (MSVCRT.@)
*/