Fixes bug [53826](https://bugs.winehq.org/show_bug.cgi?id=53826).
--
v13: 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.
https://gitlab.winehq.org/wine/wine/-/merge_requests/1148
Since multiple interfaces can hold onto it, we need to refcount it. In order to
do this just refcount the parent device, and close the handle only when the
parent device refcount reaches 0.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/1615
Fixes an out of bounds access in `show_popup`.
```c
if (menu->FocusedItem != NO_SELECTED_ITEM)
{
menu->items[menu->FocusedItem].fState &= ~(MF_HILITE|MF_MOUSESELECT); // <- can crash here
menu->FocusedItem = NO_SELECTED_ITEM;
}
```
Menu resets focused item on show, not on close.
If items were later deleted, next time user opens the menu, menu can crash on out of bounds access and won't show up again, as menu thinks it's still on screen.
In other words:
- open split button dropdown
- click on any item
- clear dropdown items
- open dropdown again
Menu borked and won't open again.
Source for the testing app for reproduction.
[test.c](/uploads/2f703f63891b33e1a0eb0fcd27c912b7/test.c)
I guess, the alternative is to reset focused item when menu is closed, but not sure where's the best place to do that, haven't dug deep enough.
--
v5: win32u: Reset focused item if it was removed when removing a menu item
https://gitlab.winehq.org/wine/wine/-/merge_requests/1554
On Wed Nov 30 10:54:56 2022 +0000, Georg Lehmann wrote:
> Yes, we can remove it when we stop using direct calls for descriptor set
> updates. But at the moment I really don't want to have worse performance
> with descriptor buffers compared to descriptor sets caused by wine.
> Especially since it's unlikely that Rémi's work will be in 8.0.
> This is not just some theoretical problem. With the current non direct
> calls, vkd3d-proton's descriptor buffer path regresses performance for
> radv users.
I'm more optimistic about 8.0. Anyway, I wouldn't mind committing it if we need to. At the same time, since there is an active work on the final solution, we may as well wait a few days and see how it goes. Let me defer that to Alexandre (I think he took over that optimization work).
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/1552#note_18096
On Wed Nov 30 17:41:13 2022 +0000, Piotr Caban wrote:
> I've finally found time to review it properly. Sorry for the delay.
> The patch needs lots of cleanup - starting from separating it into
> multiple patches (preferably adding one function in every patch) and
> changing commit message to describe what the patch implements (instead
> of what application it fixes). Taking in account next comments, I would
> suggest picking one function first and sending more patches after it
> gets in.
> I'm worried about adding the stubs (instead of full implementation). The
> functions are returning reference to object that can never be NULL on
> Windows. I'm expecting it to crash if application tries to use returned object.
> On the implementation note, I've done some initial testing of
> _Cout_func. It looks like it's almost compatible with msvcr80. The only
> difference I have found is that it uses __clrcall calling convention for
> virtual functions. I haven't found documentation for it but it seems to
> be similar to __fastcall (it additionally allows lazy compilation on
> function call but it can be probably ignored). Anyway I think that the
> way to go is to either copy implementation from msvcp and change
> relevant calling conventions or try to use PARENTSRC (I'm not sure if it
> will work well without trying).
Thanks Piotr for detailed analysis.
I have found following information about `__clrcall`:
https://learn.microsoft.com/en-us/cpp/cpp/clrcall?view=msvc-140
Unfortunately I don't know how `__clrcall` could be implemented
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/1418#note_18094