Fixes regression introduced by 35c8f15bc67f7602438fe0c39a69ff6ddf6b8297
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=55215
We already test for an invalid pointer, those tests don't really help.
The test against DrawTextA crashes on windows sometimes, the other test shows that windows probably just overruns the stack variable:
`textheight = DrawTextExA((HDC)0xdeadbeef, (LPSTR)0xdeadbeef, 100, &rect, 0, 0);`
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/3276
This MR attempts to bring Wine's handling of `setlocale` and `_create_locale` more in line with the behavior of native >= `msvcr110`. It does this by replacing the usage of the LCID based `GetLocaleInfo` with the sname based `GetLocaleInfoEx`. `GetLocaleInfo` doesn't support neutral locales, even on native, which causes problems with neutral Chinese locales like `zh-Hans` and `zh-Hant`.
It also improves the accuracy of the internal `__lc_locale_name_func`, as tests indicate that it returns `LOCALE_SNAME`s instead of ISO 639 language names.
Potential future improvements:
* Modifying the generation of the `pclmap` and `pcumap` fields of `threadlocaleinfostruct` to work on WCHARs.
* I've done some changes to `__thread_data` which make it not fully match native, I'll submit a follow up which fixes this.
--
v4: make_unicode: rename Hong Kong SAR China to Hong Kong SAR to match native behavior.
msvcrt: Use GetLocaleInfoEx to compare locale info.
msvcrt: Remap synonyms to snames.
msvcrt: Skip exhaustive locale search with valid snames.
msvcrt: Convert locale_to_LCID to snames.
msvcrt: Use snames instead of LCIDs in create_locinfo.
msvcr120/tests: Check ___lc_locale_name_func with neutral Chinese locales.
msvcr110/tests: Add tests for new setlocale behaviors.
https://gitlab.winehq.org/wine/wine/-/merge_requests/3050
--
v2: Release 8.0.2.
winedump: Fix out of bounds access (spotted by GCC13).
wordpad: Resize buttons of toolbar to make them align with height of the font list combox.
winemenubuilder: Skip desktop integration for certain associations.
wine.inf: Put the Clients key in the right place.
winemac: Initialize retina_on to avoid incorrect cached display data in high-res/retina mode.
winemac.drv: Force a window in front of its peers if its level is decreased.
threadpoolwinrt: Forward a Release() to a Release() method.
ntdll: Avoid integer overflow in block_get_subheap().
mfreadwrite: Fix an address of operator typo.
winemac: Don't constrain surface dimensions to the onscreen part of a window.
winemac: Set the Cocoa window contentMaxSize to the size limits from constrain_window_frame().
winemac: Refactor constrain_window_frame() to use separate origin and size arguments.
include: Fix IDirectXVideoDecoderService declaration in dxva2api.idl.
include: Fix c++ compiler error with msxml2.idl.
activeds: Free memory on error paths (coverity).
mshtml: Store minimum compat mode required for events in the ctor table.
mshtml: Fix URI leak in NewURI on failure.
mshtml: Fix nsIFile dir leak in init_xpcom.
mshtml: Fix factory leak in init_nsio.
winemac: Fix memory leak in UpdateDisplayDevices.
mshtml: Fix nsparser leak if script_elem_from_nsscript failed.
mshtml: Fix nsuri leak if create_channelbsc failed.
mshtml: Fix nsscript leak in bind_event_scripts.
mshtml: Fix nsevent leak in create_document_event.
evr: Fix incorrect integral computation.
msvcrt: Fix crash when rethrowing after a non-C++ exception on x86_64.
winedbg: Don't crash when no search path has been set.
ntdll: Open application manifest files with FILE_SHARE_DELETE.
kernel32/tests: Test for manifest file open share mode in CreateActCtxW.
wined3d: Add GPU information for AMD Raphael.
shlwapi: Implement StrFormatByteSizeEx.
ntdll: Fix typo in the check for hidden files.
ntdll: Set xattr in NtCreateFile if inferred and requested attributes don't match.
ntdll: Only infer hidden attribute from file name if xattr is not present.
ntdll: Handle hidden file names inside get_file_info instead of after it.
ntdll/tests: Add test for file attributes of files with names beginning with a dot.
ntdll: Make fd_set_file_info() static.
mfplat: Implement MFCreatePathFromURL().
dxdiag: Ignore option /64bit on the commandline.
findstr: Add basic functionality.
include/msvcrt: Add __WINE_(DEALLOC|MALLOC) attributes to _strdup and _wcsdup.
This merge request has too many patches to be relayed via email.
Please visit the URL below to see the contents of the merge request.
https://gitlab.winehq.org/wine/wine/-/merge_requests/3168
In HttpSendRequestW and HttpSendRequestExW, if the header pointer is not
null but the length parameter is 0, the header length should be derived
from the string length instead.
In HttpSendRequestA and HttpSendRequestExA, on the same scenario, the
function should fail instead.
--
v2: wininet: Handle http headers correctly when length is 0
https://gitlab.winehq.org/wine/wine/-/merge_requests/3269