From 5d4de2ac45574c94a40ae1d09098bf347cff2dfa Mon Sep 17 00:00:00 2001 From: Eric Pouech Date: Fri, 29 Oct 2010 15:39:42 +0200 Subject: [PATCH] msvcrt: Use parameter checking macros in vsn(w)printf_s_l. --- dlls/msvcrt/wcs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dlls/msvcrt/wcs.c b/dlls/msvcrt/wcs.c index a100f317de5..1042008d3e9 100644 --- a/dlls/msvcrt/wcs.c +++ b/dlls/msvcrt/wcs.c @@ -1050,7 +1050,7 @@ int CDECL MSVCRT_vsnprintf_s_l( char *str, MSVCRT_size_t sizeOfBuffer, if(ret<0 || ret==len) { if(count!=MSVCRT__TRUNCATE && count>sizeOfBuffer) { - MSVCRT__invalid_parameter( NULL, NULL, NULL, 0, 0 ); + MSVCRT_INVALID_PMT("str[sizeOfBuffer] is too small"); *MSVCRT__errno() = MSVCRT_ERANGE; memset(str, 0, sizeOfBuffer); } else @@ -1188,7 +1188,7 @@ int CDECL MSVCRT_vsnwprintf_s_l( MSVCRT_wchar_t *str, MSVCRT_size_t sizeOfBuffer if(ret<0 || ret==len) { if(count!=MSVCRT__TRUNCATE && count>sizeOfBuffer) { - MSVCRT__invalid_parameter( NULL, NULL, NULL, 0, 0 ); + MSVCRT_INVALID_PMT("str[sizeOfBuffer] is too small"); *MSVCRT__errno() = MSVCRT_ERANGE; memset(str, 0, sizeOfBuffer*sizeof(MSVCRT_wchar_t)); } else