Some distros arbitrary flags into clang config files without guarding it for applicable targets, which breaks cross compilation.
--
v3: winegcc: Support --no-default-config argument.
configure: Use --no-default-config option on clang when available.
configure: Fix action-if-no handling in WINE_TRY_PE_CFLAGS macro.
https://gitlab.winehq.org/wine/wine/-/merge_requests/4492
Currently, if a probe fails, it will print the line number of the [test]
block the probe is in, not the line number of the probe itself. This
makes it somewhat difficult to debug.
This commit makes it print the line number of the probe as well.
CC @zfigura
--
https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/499
On Mon Nov 27 20:35:08 2023 +0000, Gabriel Ivăncescu wrote:
> Yeah. As I said below, I can easily just get rid of the tests and do the
> right thing with a comment. Silently dropping events sounds like a bad
> idea to me, it will make it hard to debug if something broken ever
> depends on it. And it's not like it's more code, either, so better make
> it correct.
My guess is that you wouldn't be able to reproduce that with JS. If that's the case, then web pages can't depend on that (otherwise we'd have a way to crash web browser from JS).
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/4380#note_53978
> As for the "hide problems in the future", I actually think the exact opposite. Right now, we use the document's outer_window in same way, except it's completely broken and can access invalid memory if the outer window happens to die, which would be very hard to debug (especially considering most apps using mshtml are bloated and slow with millions of frameworks).
Yes, it would be nice to fix that. One fix for that is to simply reset the pointer to NULL. My understanding is that the actual reason we can't do that is iframe navigation test and we already know that the test works because on native, the document interface doesn't change. So what you do is essentially working around that problem, not fixing it.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/4380#note_53977
On Mon Nov 27 17:34:03 2023 +0000, Jacek Caban wrote:
> This should really use `!iface_cmp()` to make sure it's not one more
> instance of wrappers that native uses in similar places. However, trying
> to do that crashes on native, which is just one more reason to believe
> that detached documents are broken there and trying too hard to mimic it
> does not make sense. I think that you're misinterpreting some quirks
> that are not really interested in the first place. I suggest to drop
> those tests and just do the right thing: don't send any events on
> detached document, maybe even fail early on an attempt to use such storage.
Yeah. As I said below, I can easily just get rid of the tests and do the right thing with a comment. Silently dropping events sounds like a bad idea to me, it will make it hard to debug if something broken ever depends on it. And it's not like it's more code, either, so better make it correct.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/4380#note_53976
And of course the gitlab subscription reply doesn't work via email…
Well that's why I wanted it before code freeze, so any possible regressions are detected now. Isn't that the point?
For storage events, yeah I can easily get rid of the test and just keep the current "correct" behavior with a comment. I'd rather keep that than silently drop events (or even if it's logged, it's not that obvious), because that's 1) incorrect and 2) it's extremely hard to debug if something broken ever depends on it. Plus, it's not like sending the events is extra code than silently dropping them, most of the patch is in the tests.
As for the "hide problems in the future", I actually think the exact opposite. Right now, we use the document's outer_window in same way, except it's completely broken and can access invalid memory if the outer window happens to die, which would be very hard to debug (especially considering most apps using mshtml are bloated and slow with millions of frameworks).
What problem would this hide? The things that *are* different than before (e.g. parentWindow), are tested so they're fixed and correct, with the others being same as before, except not randomly crashing in some cases.
Maybe it's not by itself a strong argument, but outer_window on document is now just simply broken and I'd like to fix that before the code freeze.
Another reason is that such things would also be very hard to figure out if something even depends on (lack of events especially if it's corner case like this). Considering it also fixes a broken reference from outer_window that's completely arbitrary right now, I think that's reasonable enough.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/4380#note_53975
This MR fixes remaining Clang warnings related to enums for vkd3d in Wine tree, both in mingw and msvc mode.
--
v2: configure: Enable -Wenum-conversion warnings.
gitlab: Remove no longer needed -Wno-enum-conversion from build-mac.
https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/493
---
I don't see a method to wait for a fence, at least not without having a
command queue. A suggestion I found online goes along the lines of:
if (fence->GetCompletedValue != expected)
{
HANDLE ev = CreateEvent(...);
fence->SetEventOnCompletion(expected, ev);
WaitForSingleObject(ev, INFINITE);
CloseHandle(ev);
}
Which I could write, but would be untested dead code as long as the
other method is a stub. So busy waiting and writing one fixme every time
we busy wait seems like a better choice for now.
--
v2: vkd3d: Forward MakeResident to EnqueueMakeResident.
vkd3d: Improve the EnqueueMakeResident stub.
https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/488
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=55843
NtUserSetThreadDesktop, called from winstation_init may call into update_display_cache before sysparams_init, when virtual desktop mode is initialized, and so, before config_key is initialized. This end up with a failure to update the display mode cache, error messages a longer start times.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/4526
This is the third (and last) part of the Wayland driver Vulkan subseries:
1. Implement `vkQueuePresentKHR` and support reporting `VK_ERROR_OUT_OF_DATE_KHR` and `VK_ERROR_SURFACE_LOST_KHR`.
2. Misc. enhancements/fixes to ensure the subsurface containing the vulkan rendering is displayed properly.
3. Implement a couple of remaining Vulkan functions.
With this MR you can start enjoying some of your games with the Wayland driver (either directly with Vulkan or with a D3D->Vulkan translation). Please note, however, that we don't currently support what's needed for mouselook (you will currently get erratic view movement), so most first-person 3D games are not playable yet.
Thanks!
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/4522
The more I look at it the more I'm convinced that the change to keep outer window reference is not worth it. Storage events seem just outright broken on native, so that's not a good reason.
Looking at Gecko, I can see that it does what we currently do and resets outer window pointer from inner window and document when inner window changes. It means that whatever we do on Wine side, everything that depends on Gecko will still not "work".
The change is also quite invasive. It changes a meaning of pointers that are used module-wide, so there is some risk associated with it and the motivation seems questionable to me. Why do you need that in the first place? This is not something you've actually seen mattering for real-world use case, right?
Another thing about it is that it's likely to hide some problems in the future. Resetting outer pointer is nice to have a clear cut when inner window is no longer valid. It's not a strong argument, if we really have a reason to change it, we may, but I'd like to know the reason.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/4380#note_53941
Jacek Caban (@jacek) commented about dlls/mshtml/tests/events.c:
> + ok(hres == S_OK, "get_documentMode failed: %08lx\n", hres);
> + ok(V_VT(&var) == VT_R4, "V_VT(documentMode) = %u\n", V_VT(&var));
> + document_mode = V_R4(&var);
> + }
> + IHTMLDocument6_Release(doc6);
> + }
> +
> + hres = IHTMLWindow2_QueryInterface(window, &IID_IHTMLWindow6, (void**)&window6);
> + ok(hres == S_OK, "Could not get IHTMLWindow6: %08lx\n", hres);
> + IHTMLWindow2_Release(window);
> + window = NULL;
> +
> + hres = IHTMLWindow6_get_sessionStorage(window6, &tmp_session_storage);
> + ok(hres == S_OK, "get_sessionStorage failed: %08lx\n", hres);
> + ok(tmp_session_storage != NULL, "session_storage == NULL\n");
> + ok(tmp_session_storage != session_storage[0], "session_storage after navigation same as old session_storage\n");
This should really use `!iface_cmp()` to make sure it's not one more instance of wrappers that native uses in similar places. However, trying to do that crashes on native, which is just one more reason to believe that detached documents are broken there and trying too hard to mimic it does not make sense. I think that you're misinterpreting some quirks that are not really interested in the first place. I suggest to drop those tests and just do the right thing: don't send any events on detached document, maybe even fail early on an attempt to use such storage.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/4380#note_53940
I don't think there's any reason to use the conversion context to allocate this memory, it's briefly used to build the host extension list and released right away.
--
v4: winevulkan: Fix python linter warnings.
winevulkan: Drop the WINEVULKAN_QUIRK_IGNORE_EXPLICIT_LAYERS quirk.
winevulkan: Use a local instance variable instead of phys_dev->instance.
winevulkan: Restore utils messengers when vkCreateInstance needs more physical devices.
winevulkan: Restore debug callbacks when vkCreateInstance needs more physical devices.
https://gitlab.winehq.org/wine/wine/-/merge_requests/4488
Conflicts with !450 but can probably go upstream before it since backend changes here are minimal.
--
v5: vkd3d-shader/dxil: Handle the DXIL SWITCH instruction.
vkd3d-shader: Rename shader_instruction_array_add_icb() to shader_instruction_array_add_opaque_param().
vkd3d-shader/dxil: Handle the DXIL PHI instruction.
https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/491
I don't think there's any reason to use the conversion context to allocate this memory, it's briefly used to build the host extension list and released right away.
--
v3: winevulkan: Fix python linter warnings.
winevulkan: Drop the WINEVULKAN_QUIRK_IGNORE_EXPLICIT_LAYERS quirk.
winevulkan: Use a local instance variable instead of phys_dev->instance.
winevulkan: Allocate memory for VkInstanceCreateInfo with malloc.
winevulkan: Allocate memory for VkDeviceCreateInfo with malloc.
winevulkan: Restore utils messengers when vkCreateInstance needs more physical devices.
winevulkan: Restore debug callbacks when vkCreateInstance needs more physical devices.
https://gitlab.winehq.org/wine/wine/-/merge_requests/4488
The point here is to make the default implementation similar to winex11, supporting a standalone systray window. Later, we could refactor the interface to remove the duplicated systray code from the user drivers.
--
v4: explorer: Cache the balloon window position.
explorer: Support standalone systray window mode.
explorer: Use an explicit display constant for hidden icons.
explorer: Handle balloon timer in the icons window proc.
explorer: Position the balloons relative to the icon windows.
explorer: Use the icon windows for their tooltips.
explorer: Display the individual systray icon windows.
explorer: Create individual windows for the systray icons.
explorer: Split systray add/remove from show/hide_icon.
explorer: Remove unnecessary displayed icon array.
https://gitlab.winehq.org/wine/wine/-/merge_requests/3171
Signed-off-by: Eric Pouech <epouech(a)codeweavers.com>
--
v2: ntdll: Search for CtrlRoutine in kernelbase.
ntdll: RtlFindExportedRoutine returns NULL on forwarded function.
https://gitlab.winehq.org/wine/wine/-/merge_requests/4523
On Mon Nov 27 11:00:09 2023 +0000, Matteo Bruni wrote:
> Good catch, I'll send that fix in a followup (unless Paul wants to take
> care of it as well).
Actually Paul did this in the final (now merged) version of this MR, so we're good.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/4459#note_53888
This serie adds a couple of test for CreateProcess around
std handles inheritance, depending on several options (cui/gui,
use (or no use) of STARTF_USESTDHANDLES, type of handles...).
This requires revisiting the existing tests to allow for more
flexibility in implementing the new tests (and potentially
others if needed).
--
v2: kernel32/tests: Add tests for std handles inheritance in CreateProcess.
kernel32/tests: Revisit argument generation in CreateProcess tests.
kernel32/tests: Detect null/invalid handles, return file type as well.
kernel32/tests: Extend returned values for cui/gui tests.
https://gitlab.winehq.org/wine/wine/-/merge_requests/4378
The point here is to make the default implementation close to winex11, supporting a standalone systray window, and then refactor the interface to remove the duplicated code from the user drivers.
--
v3: explorer: Cache the balloon window position.
explorer: Support standalone systray window mode.
explorer: Use an explicit display constant for hidden icons.
explorer: Handle balloon timer in the icons window proc.
explorer: Position the balloons relative to the icon windows.
explorer: Use the icon windows for their tooltips.
explorer: Display the individual systray icon windows.
explorer: Create individual windows for the systray icons.
explorer: Split systray add/remove from show/hide_icon.
explorer: Remove unnecessary displayed icon array.
https://gitlab.winehq.org/wine/wine/-/merge_requests/3171
On Mon Nov 27 00:44:27 2023 +0000, Shmerl wrote:
> Sorry for slight off-topic, but is there a way to test it with current Wine?
> I was trying something like this:
> ```
> DISPLAY='' WAYLAND_DISPLAY='wayland-0' wine notepad.exe
> ```
> But it's not working:
> ```
> 009c:err:winediag:nodrv_CreateWindow Application tried to create a
> window, but no driver could be loaded.
> 009c:err:winediag:nodrv_CreateWindow L"The explorer process failed to start."
> 009c:err:systray:initialize_systray Could not create tray window
> 002c:err:winediag:nodrv_CreateWindow Application tried to create a
> window, but no driver could be loaded.
> 002c:err:winediag:nodrv_CreateWindow L"Make sure that your X server is
> running and that $DISPLAY is set correctly."
> ```
> Or it still needs more bits before it can be tested?
you need to modify regedit, for details see here
https://gitlab.winehq.org/wine/wine/-/merge_requests/3909#note_46166
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/4456#note_53856
Fixes periodic crashes in PowerPoint 365
--
v7: d2d1: Acquire lock before attempt to draw to device context
d2d1: Add test for singlethreaded draw
d2d1: Add test for multithreaded draw
https://gitlab.winehq.org/wine/wine/-/merge_requests/4452
Sorry for slight off-topic, but is there a way to test it with current Wine?
I was trying something like this:
```
DISPLAY='' WAYLAND_DISPLAY='wayland-0' wine notepad.exe
```
But it's not working:
```
009c:err:winediag:nodrv_CreateWindow Application tried to create a window, but no driver could be loaded.
009c:err:winediag:nodrv_CreateWindow L"The explorer process failed to start."
009c:err:systray:initialize_systray Could not create tray window
002c:err:winediag:nodrv_CreateWindow Application tried to create a window, but no driver could be loaded.
002c:err:winediag:nodrv_CreateWindow L"Make sure that your X server is running and that $DISPLAY is set correctly."
```
Or it still needs more bits before it can be tested?
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/4456#note_53850
Supersedes !482.
Instead of only storing the value that each variable's component has at
the moment of the instruction currently handled by copy-prop, we store
the trace of all the historic values with their timestamps, i.e. the
instruction index on which the value was stored.
This allow us to query the value that the variable's component had at the time of a swizzle's load instead of the swizzle instead, which also preempts copy-prop from getting stuck in an infinite loop, as which the added tests.
--
v4: vkd3d-shader/hlsl: Use values at the time of the swizzle's load in copy-propagation.
vkd3d-shader/hlsl: Record trace of stored values in copy-propagation.
vkd3d-shader/hlsl: Move index_instructions() up.
tests: Test current failure when propagating swizzles.
https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/487
The RoShade installer crashes because of ole32 trying to release
the OLE drop target from another process (which can't be accessed
despite it being a valid pointer).
Windows probably supports this behavior (but implementing it here
would require extra work and this is enough to make this app work).
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=54912
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/4511
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=45123
In `gdiplus/graphicspath.c` calculating the Pythagorean addition is needed, which is defined as:
a ⊕ b = sqrt(a^2+b^2)
This is hypotenuse, or the length of the longest side of a right-angled triangle, that we know the other 2 sides, a and b.
https://en.wikipedia.org/wiki/Pythagorean_addition
By using `sqrt(a * a + b * b)`, for large (or small) `a` or `b`, there is a possibility of overflow (underflow),
although the result itself is not that big (small) to cause overflow (underflow).
To overcome this problem, there are implementations of hypotenuse that do not use power of 2,
and use other methods to calculate the result.
To calculate `a ⊕ b`, you can easily use `hypotf(a,b)`.
https://en.cppreference.com/w/cpp/numeric/math/hypot
--
v5: gdiplus/font: Avoid computation overflow and underflow by using hypotf
gdiplus/graphicspath: Avoid computation overflow and underflow by using hypotf.
https://gitlab.winehq.org/wine/wine/-/merge_requests/4475
This is my first time contributing wine and there are a lot of things I'm not sure about, so any comments are welcome. :)
--
v12: kernel32: add sync barrier test
kernel32: impl sync barrier
https://gitlab.winehq.org/wine/wine/-/merge_requests/4372
I don't think there's any reason to use the conversion context to allocate this memory, it's briefly used to build the host extension list and released right away.
--
v2: winevulkan: Allocate memory for VkInstanceCreateInfo with malloc.
winevulkan: Allocate memory for VkDeviceCreateInfo with malloc.
https://gitlab.winehq.org/wine/wine/-/merge_requests/4488
--
v10: user32: Pass real argument to NtUserGetClassName in RealGetWindowClass{A/W}.
win32u: Add support for retrieving real window class ID across processes.
user32: Set real window class ID for user32 static controls.
https://gitlab.winehq.org/wine/wine/-/merge_requests/4092