vsnprintf isn't always guaranteed to null terminate its output, depends on the
version of msvcrt used.
See !8256 for more information.
supersedes !8256
--
v2: include: Make sure to null terminate string in wine_dbg_vsprintf.
https://gitlab.winehq.org/wine/wine/-/merge_requests/8404
Microsoft's documentation says:
> The `vsnprintf` function always writes a null terminator, even if it truncates the output. When you use `_vsnprintf` and `_vsnwprintf`, the buffer is null-terminated only if there's room at the end (that is, if the number of characters to write is less than count).
For `_UCRT` and `_MSVCR_VER >= 140`, `vsnprintf` calls `__stdio_common_vsprintf` with `_CRT_INTERNAL_PRINTF_STANDARD_SNPRINTF_BEHAVIOR`, and everything works, a null byte is appended, everything is fine.
If not, `vsnprintf` calls `_vsnprintf` directly and no null byte will be added if the buffer is not big enough. This happens in, for example, kernel32. And this breaks `wine_dbg_vsprintf`, which passes result of `vsnprintf` to `strlen` and goes out-of-bound.
In msvcrt.spec, we also have `vsnprintf` as an alias of `_vsnprintf`, I didn't touch that since I don't know if that's deliberate. But this alias _is_ used (by e.g. winecrt0, i think?), if this one is also wrong then it might break other things.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/8256
Used by Diablo IV's screen reader.
--
v4: sapi/xml: Add a stub implementation using libxml2.
sapi/tts: Support XML-related flags in ISpVoice::Speak.
sapi/tests: Add some SSML tests in tts.
sapi/tests: Introduce simulate_output option in tts.
sapi/tests: Copy SPVTEXTFRAG list into a contiguous array.
https://gitlab.winehq.org/wine/wine/-/merge_requests/8390
structuredquery is required to support AQS filters in Windows.Devices.Enumeration's `FindAllAsync` methods, this adds a basic set of stubs to get the ball rolling.
--
v11: dlls/structuredquery: Add stubs for IQueryParserManager.
dlls/structuredquery/tests: Add conformance tests for IQueryParserManager.
https://gitlab.winehq.org/wine/wine/-/merge_requests/6788
There seem to be a few special cases here, of which the main one is `DEVPKEY_DeviceInterface_Enabled`. This property key does not have an actual registry entry, but the value read by `SetupDiGetDeviceInterfacePropertyW` corresponds to whether the interface is enabled/linked or not. Likewise, the key cannot be written to either, with `SetupDiSetDeviceInterfacePropertyW` returning `ERROR_ACCESS DENIED`.
--
v7: ntoskrnl.exe/test: Add tests for SetupDiGetDeviceInterfacePropertyW with enabled interfaces.
setupapi: Implement SetupDiGetDeviceInterfacePropertyW.
setupapi: Implement SetupDiSetDeviceInterfacePropertyW.
setupapi/tests: Add tests for SetupDi{Set,Get}DeviceInterfacePropertyW.
https://gitlab.winehq.org/wine/wine/-/merge_requests/8379
check_json_ uses wcslen on the passed json string, which is no good for
non-null terminated ones. It should have a length parameter.
* * *
(made a draft since i am not sure what this test is meant to test, see comment.)
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/8345