This cleans up `LDR_DONT_RESOLVE_REFS` checks in preparation for !7.
--
v2: ntdlll: Remove redundant LDR_DONT_RESOLVE_REFS checks before calling process_attach().
ntdll: Skip DLL initialization and ldr notification entirely if DONT_RESOLVE_DLL_REFERENCES is set.
kernel32/tests: Test for unexpected loader notification for import dependency loaded with DONT_RESOLVE_DLL_REFERENCES.
kernel32/tests: Test for unexpected LDR_PROCESS_ATTACHED flag in import dependency loaded with DONT_RESOLVE_DLL_REFERENCES.
kernel32/tests: Add basic tests for internal flags of modules loaded with DONT_RESOLVE_DLL_REFERENCES.
https://gitlab.winehq.org/wine/wine/-/merge_requests/7347
Allow the user to press Ctrl-C to abort lengthy DIR (or DIR /p, etc.) operations.
--
v13: programs/cmd: Implement ability to abort lengthy directory operations via Ctrl-C.
https://gitlab.winehq.org/wine/wine/-/merge_requests/7322
On Mon Feb 17 19:22:08 2025 +0000, eric pouech wrote:
> thanks for taking the time to update your patch
> unfortunately, it fails on wine regression test
> the attached patch should solve this
> [patch.ctrlc](/uploads/84ae84d1c5cf3d3dfc19904c673bc906/patch.ctrlc)
> also, any reason you changed the ctrl event for and automatic reset?
> actually, I was puzzled with the previous versions with a manual reset
> (my first guess would have been to implement it with an automatic reset)
> I tried things like '(dir /s \\\* || echo aaaaa) && dir \*' (and halting
> the first dir command with ctrl-c) on native:
> * does break the first dir command,
> * executes the RHS of || (as the dir command failed because of the
> ctrl-c),
> * prints the 'aaaaa' string
> * executes the RHS of && (as last command of LHS, eg echo, did succeed),
> * outputs just the directory header (but nothing else) for the second dir
> which fits better with a manual reset (it could be implemented in native
> with something else, like a global variable set in the event handler
> -requires atomic ops-)
Thank you for the patch. I will try to get that integrated sometime today. I'll be traveling for the next few days and will have limited ability during that time to address further concerns.
Automatic vs. manual reset were based on my thinking about whether the function WCMD_ctrlc_status would be called more than once per command iteration. If called only once then ownership of the status passes to the caller and thus automatic reset is cleaner. However, thinking further about this, it probably makes sense to switch back to manual reset, in case future callers (i.e. perhaps for different internal commands, etc.) might want to call it more than once per iteration. That, and the fact that there is a manual reset anyway before command launch in the loop toward the end of wmain suggests that a manual reset would be better, so I will switch back when I submit the changes containing your patch.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/7322#note_94891
thanks for taking the time to update your patch
unfortunately, it fails on wine regression test
the attached patch should solve this
[patch.ctrlc](/uploads/84ae84d1c5cf3d3dfc19904c673bc906/patch.ctrlc)
also, any reason you changed the ctrl event for and automatic reset?
actually, I was puzzled with the previous versions with a manual reset (my first guess would have been to implement it with an automatic reset)
I tried things like '(dir /s \\\* || echo aaaaa) && dir \*' (and halting the first dir command with ctrl-c) on native:
* does break the first dir command,
* executes the RHS of || (as the dir command failed because of the ctrl-c),
* prints the 'aaaaa' string
* executes the RHS of && (as last command of LHS, eg echo, did succeed),
* outputs just the directory header (but nothing else) for the second dir
which fits better with a manual reset (it could be implemented in native with something else, like a global variable set in the event handler -requires atomic ops-)
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/7322#note_94879
This adds Mach thread priority support (both in the application and realtime band) and recalculates thread priorities when the process priority changes.
Part 3, which is still a bit WIP deals with implementing priority boosts (for main threads and threads which are processing window messages), effectively fully replacing https://gitlab.winehq.org/wine/wine/-/merge_requests/1232.
Currently the implementation in this MR already technically overrides what https://gitlab.winehq.org/wine/wine/-/merge_requests/1232 does, if it makes sense I can also revert it here.
I added a few comments regarding the Mach thread priority API usage, as there is limited documentation available, and much was inferred from the source or by testing. If this is too verbose I can also remove that...
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/7317
I don't think these are serious problems, but Clang 20's defaults (from llvm-mingw nightly) were resulting in build failures with `--enable-werror` due to `-Wtautological-compare` and `-Wunused-function`. I hope that the buffer wrap checking is somewhat idiomatic/standard.
If necessary, I can split off the winevulkan change, but it seems minor enough to be grouped in this MR.
--
v2: rpcrt4: Pointer arithmetic fixes (-Wtautological-compare).
https://gitlab.winehq.org/wine/wine/-/merge_requests/7231
This fixes https://bugs.winehq.org/show_bug.cgi?id=52094.
For reference, here's how current_modref is being passed around (before this patch):
```mermaid
graph TB
fii["fixup_imports_ilonly<br><em style='color:#ff0'>(directly sets current_modref)</em>"]
fi["fixup_imports<br><em style='color:#ff0'>(directly sets current_modref)</em>"]
pa["process_attach<br><em style='color:#ff0'>(directly sets current_modref)</em>"]
ld[load_dll]
id["import_dll<br><em style='color:#0f0'>(directly uses current_modref)</em>"]
bin["build_import_name<br><em style='color:#0f0'>(directly uses current_modref)</em>"]
foe["find_ordinal_export<br><em style='color:#0f0'>(uses current_modref for relay)</em>"]
ffe["find_forwarded_export<br><em style='color:#0f0'>(directly uses current_modref)</em>"]
fne[find_named_export]
MI[MODULE_InitDLL]
fii --> ld
fi --> id
pa --> MI -.-> DllMain
id --> bin
id --> ld
id --> foe
id --> fne --> foe --> ffe --> foe
ffe --> fne
ffe --> bin
style DllMain color:red;
```
--
v12: ntdll: Remove superflous NULL check for importer.
ntdll: Properly track refcount on dynamic imports of export forwarders.
ntdll: Explicitly ignore dynamic (GetProcAddress) importers as relay/snoop user module.
ntdll: Properly track refcount on static imports of export forwarders.
ntdll: Register module dependency for export forwarders regardless of whether the dependency is already loaded.
ntdll: Don't re-add a module dependency if it already exists.
ntdll: Register module dependency for export forwarders only after successful resolution.
https://gitlab.winehq.org/wine/wine/-/merge_requests/7
This resolves the issue in StudioTax where the bounding box dimensions is reported as 0.
Because the height is less than 0, the check for height in GdipAddPathRectangle fails,
and the X and Y coordinates of the points is never set.
I am fairly ignorant of this code, this seems like a good approach, however I am happy for guidance from others more familiar in how gdiplus works.
--
v3: gdiplus: Fix text height calculation when exceeding rect
gdiplus: Check for NoClip in text height calculation
https://gitlab.winehq.org/wine/wine/-/merge_requests/5360
Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com>
--
v3: windowscodecs: Implement CreateQueryWriter().
windowscodecs/metadata: Base returned query handlers on metadata handlers.
windowscodecs/metadata: Return query writer object from GetMetadataByName() when block writer is used.
windowscodecs/metadata: Handle empty items in queries.
windowscodecs/metadata: Use separate helpers to parse query items.
windowscodecs/metadata: Add a helper to parse query index syntax.
windowscodecs/metadata: Collect query components before assigning values.
windowscodecs/metadata: Use VT_LPWSTR type instead of BSTRs when parsing queries.
windowscodecs/tests: Add some tests for the query reader container format.
windowscodecs/tests: Add some tests for CreateQueryWriterFromReader().
windowscodecs/tests: Add query reader tests for live block reader updates.
windowscodecs/tests: Add some tests for CreateQueryWriter().
windowscodecs/metadata: Share implementation between query reader and writer objects.
windowscodecs/tests: Add some query tests with the Unknown reader.
https://gitlab.winehq.org/wine/wine/-/merge_requests/7329