diff --git a/dlls/msvcrt/dir.c b/dlls/msvcrt/dir.c index 5e84e38a005..aaf2f8a4145 100644 --- a/dlls/msvcrt/dir.c +++ b/dlls/msvcrt/dir.c @@ -828,7 +828,7 @@ int CDECL MSVCRT__getdrive(void) WCHAR buffer[MAX_PATH]; if (GetCurrentDirectoryW( MAX_PATH, buffer ) && buffer[0] >= 'A' && buffer[0] <= 'z' && buffer[1] == ':') - return toupperW(buffer[0]) - 'A' + 1; + return MSVCRT_towupper(buffer[0]) - 'A' + 1; return 0; } diff --git a/dlls/msvcrt/file.c b/dlls/msvcrt/file.c index d20fa8e6a23..9c42aa56993 100644 --- a/dlls/msvcrt/file.c +++ b/dlls/msvcrt/file.c @@ -3166,7 +3166,7 @@ int CDECL MSVCRT__wstat64(const MSVCRT_wchar_t* path, struct MSVCRT__stat64 * bu /* FIXME: rdev isn't drive num, despite what the docs says-what is it? */ if (MSVCRT_iswalpha(*path) && path[1] == ':') - buf->st_dev = buf->st_rdev = toupperW(*path) - 'A'; /* drive num */ + buf->st_dev = buf->st_rdev = MSVCRT_towupper(*path) - 'A'; /* drive num */ else buf->st_dev = buf->st_rdev = MSVCRT__getdrive() - 1; diff --git a/dlls/msvcrt/msvcrt.h b/dlls/msvcrt/msvcrt.h index 7c92abc4fda..4a13501993a 100644 --- a/dlls/msvcrt/msvcrt.h +++ b/dlls/msvcrt/msvcrt.h @@ -1200,6 +1200,7 @@ double parse_double(MSVCRT_wchar_t (*)(void*), void (*)(void*), void*, MSVCRT_pt int __cdecl MSVCRT_wcsncmp(const MSVCRT_wchar_t*, const MSVCRT_wchar_t*, MSVCRT_size_t); int __cdecl MSVCRT__wcsnicmp(const MSVCRT_wchar_t*, const MSVCRT_wchar_t*, MSVCRT_size_t); int __cdecl MSVCRT_towlower(MSVCRT_wint_t); +int __cdecl MSVCRT_towupper(MSVCRT_wint_t); /* Maybe one day we'll enable the invalid parameter handlers with the full set of information (msvcrXXd) * #define MSVCRT_INVALID_PMT(x) MSVCRT_call_invalid_parameter_handler(x, __FUNCTION__, __FILE__, __LINE__, 0) diff --git a/dlls/msvcrt/wcs.c b/dlls/msvcrt/wcs.c index 5f1d5f8e8c6..5188d4f8604 100644 --- a/dlls/msvcrt/wcs.c +++ b/dlls/msvcrt/wcs.c @@ -356,8 +356,7 @@ int CDECL MSVCRT__wcsupr_s_l( MSVCRT_wchar_t* str, MSVCRT_size_t n, while (n--) { if (!*ptr) return 0; - /* FIXME: add locale support */ - *ptr = toupperW(*ptr); + *ptr = MSVCRT__towupper_l(*ptr, locale); ptr++; }