And use that instead of duplicating those helpers across the tree.
Besides removing existing duplicates, I am planning to add yet another WinRT dll (gamepad) and we will likely add more in the future, each of those can use that, as well as potentially more common helpers.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/1045
This MR supercedes !1895 and !3073 as a solution to bug [#50771](https://bugs.winehq.org/show_bug.cgi?id=50771). Rather than fixing the problem of Wine's inability to modify the attributes of read-only files, this patch set instead implements `FileDispositionInformationEx` which the Msys2 and Cygwin runtime libriries can use to avoid needing to modify attributes.
All the flags of `FileDispositionInformationEx` are implemented with the exception of `FILE_DISPOSITION_FORCE_IMAGE_SECTION_CHECK`.
This MR improves upon !3073 by implementing `FILE_DISPOSITION_POSIX_SEMANTICS` and `FILE_DISPOSITION_ON_CLOSE` where the previous MR only implemented `FILE_DISPOSITION_DELETE` and `FILE_DISPOSITION_IGNORE_READONLY_ATTRIBUTE`.
--
v2: ntdll: Implement FILE_DISPOSITION_POSIX_SEMANTICS
server: Replace unlink member of closed_fd with disp_flags
ntdll/tests: Add tests for FILE_DISPOSITION_POSIX_SEMANTICS
https://gitlab.winehq.org/wine/wine/-/merge_requests/3122
Unix consoles (created from initial process) are inherited by child
processes for various reasons, like keeping std handles bound to that
unix console.
This differs from Windows as the default for a GUI is not to have
console attached.
If a GUI programs asks for a console, it will succeed on Windows
but fail under Wine as the Unix console is still present.
So, allow AllocConsole() to succeed when called from a GUI program
and tied to a Unix console.
(don't do it for CUI as they are already attached to a console).
This fixes Scrap Mechanic when run with '-dev' option.
(based on suggestion from Zhiyi Zhang)
Signed-off-by: Eric Pouech <epouech(a)codeweavers.com>
--
v2: kernelbase: Only inherit consoles for CUI processes.
https://gitlab.winehq.org/wine/wine/-/merge_requests/3022
--
v5: winepulse: Refactor AudioClient's Initialize to match other drivers.
wineoss: Use create_stream's channel count in AudioClient's Initialize.
winecoreaudio: Use create_stream's channel count in AudioClient's Initialize.
winealsa: Use create_stream's channel count in AudioClient's Initialize.
winepulse: Use mmdevapi's set_stream_volumes.
wineoss: Use mmdevapi's set_stream_volumes.
winecoreaudio: Use mmdevapi's set_stream_volumes.
winealsa: Use mmdevapi's set_stream_volumes.
https://gitlab.winehq.org/wine/wine/-/merge_requests/3112