reactos/sdk/lib
Bișoc George 8266f62ff6
[CRT][STDLIB] Wine-sync _mbtowc_l function code
The current _mbtowc_l code directly passes the string count size argument to cbMultiByte argument parameter to MultiByteToWideChar(). As the size of lpMultiByteStr expressed in bytes by cbMultiByte is dependent of the actual given string, the size of lpWideCharStr expressed in characters by cchWideChar is always 1.

The resulting parameters to MultiByteToWideChar() will lead to a failure as lpWideCharStr cannot accommodate the converted string if the size pointed by lpMultiByteStr is larger than the buffer wide string to receive the converted output, a Win32 error code of ERROR_INSUFFICIENT_BUFFER in other words. The fact that _mbtowc_l never fails without WINE Gecko package installed is because the codepage pointed by lc_codepage is CP_ACP and the converted output is directly given to the destination wide string parameter thus never calling MultiByteToWideChar(). Installing WINE Gecko merely unhides this problem.

As _mbtowc_l is imported from WINE and that they have updated their code (which at the same time this fixes the aforementioned problem), the following commit syncs the updated code from WINE.

CORE-16885
2020-04-28 22:41:57 +02:00
..
3rdparty [LIBXML2] Update to version 2.9.10. CORE-16952 2020-04-24 14:44:52 +02:00
atl [ATL] Add some hacks for gcc, 2020-04-04 19:55:31 +02:00
cmlib [CMAKE] Replace custom functions to built-in ones 2020-04-16 15:59:38 +03:00
comsupp Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
conutils [CONUTILS] In ConWrite(), emit an \r when a \n is encountered but not already preceded by \r. 2018-08-23 17:04:53 +02:00
cportlib [CPORTLIB][NTOS:INBV][KDCOM][FREELDR] Add ComPort library for NEC PC-98 series (#2407) 2020-03-06 19:50:31 +01:00
cpprt [CPPRT] Implement __std_terminate wrapper for Clang-CL 2019-02-12 19:31:33 +01:00
crt [CRT][STDLIB] Wine-sync _mbtowc_l function code 2020-04-28 22:41:57 +02:00
cryptlib Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
debugsup Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
delayimp [DELAYIMP] Fix/Merge definitions of __pfnDliNotifyHook2 and __pfnDliFailureHook2 2018-06-13 23:28:15 +02:00
dmilib [DRWTSN32] Add SMBIOS data to the system information (#1017) 2018-11-21 21:49:15 +01:00
dnslib Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
drivers [LWIP] Use tcp_close when both shut_rx and shut_tx are set. Fixes CORE-16868 (#2582) 2020-04-26 18:40:47 +02:00
dxguid Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
epsapi Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
evtlib [EVTLIB] Silence some DPRINTs. 2018-04-22 02:53:40 +02:00
fast486 [REACTOS] Fix misc 64 bit issues (#783) 2019-01-05 10:50:11 +01:00
fslib [BTRFS][UBTRFS][SHELLBTRFS] Upgrade to 1.7.2 2020-04-23 07:07:36 +03:00
gcc_ssp Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
inflib [CMAKE] Replace custom functions to built-in ones 2020-04-16 15:59:38 +03:00
ioevent Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
lsalib [CMAKE] Replace custom functions to built-in ones 2020-04-16 15:59:38 +03:00
nt [SDK:NT] Remove Win32-isms. 2019-09-19 02:39:59 +02:00
ppcmmu Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
pseh Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
rossym [NTOS] Add a #define __ROS_ROSSYM__ when using rossym 2020-04-09 23:00:57 +02:00
rossym_new [NTOSKRNL][ROSSYM] ZwReadFile() calls: Use explicit NULL instead of ambiguous 0. CORE-13910 2017-10-27 13:38:02 +02:00
rtl [RTL] Implement LdrpRecordUnloadEvent 2020-04-26 14:35:51 +02:00
runtmchk [RUNTMCHK] Provide fallback memset for arm builds 2019-08-20 22:28:11 +02:00
scrnsave Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
skiplist [SDK] Fix 64 bit issues 2018-07-01 14:45:21 +02:00
smlib Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
strmiids Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
tdilib [TDILIB] Make tdiGetSetOfThings() return useful status 2018-11-18 16:30:45 +01:00
tzlib [TZLIB] QueryTimeZoneData(): Don't fail if the optional values "Display", "Std", "Dlt" are missing (or too long to be captured). However fail if the timezone information is missing. 2020-04-22 00:58:32 +02:00
udmihelp [DRWTSN32] Add SMBIOS data to the system information (#1017) 2018-11-21 21:49:15 +01:00
uuid [PSDK][UUID] Import natupnp.idl from Wine Staging 4.18. CORE-16441 2019-10-20 20:01:58 +01:00
wdmguid Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
CMakeLists.txt [TIMEDATE.CPL][SYSSETUP][TZLIB] Introduce a small static library "tzlib": "TimeZone Utilities Library", and use it in timedate.cpl and syssetup.dll. 2020-04-22 00:58:32 +02:00