Module: wine
Branch: master
Commit: 14435a6d31377bb8a5d190a93eb22be66080f9d3
URL: https://source.winehq.org/git/wine.git/?a=commit;h=14435a6d31377bb8a5d190a9…
Author: Gabriel Ivăncescu <gabrielopcode(a)gmail.com>
Date: Thu Jan 2 15:07:44 2020 +0200
quartz: Reset the advise thread's timeout on each iteration.
Fixes a regression introduced by
63a6b308e91232dd55dd107595a6181c70180dd4. Because the timeout value was
always shrinked, it quickly went to 0 and then the entire advise thread
used 100% of a CPU core in applications such as Media Player Classic by
basically becoming a busy loop.
Signed-off-by: Gabriel Ivăncescu <gabrielopcode(a)gmail.com>
Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com>
Signed-off-by: Alexandre Julliard <julliard(a)winehq.org>
---
dlls/quartz/systemclock.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/dlls/quartz/systemclock.c b/dlls/quartz/systemclock.c
index 77e569d437..8122cc5b0b 100644
--- a/dlls/quartz/systemclock.c
+++ b/dlls/quartz/systemclock.c
@@ -126,13 +126,14 @@ static DWORD WINAPI SystemClockAdviseThread(void *param)
struct system_clock *clock = param;
struct advise_sink *sink, *cursor;
REFERENCE_TIME current_time;
- DWORD timeout = INFINITE;
HANDLE handles[2] = {clock->stop_event, clock->notify_event};
TRACE("Starting advise thread for clock %p.\n", clock);
for (;;)
{
+ DWORD timeout = INFINITE;
+
EnterCriticalSection(&clock->cs);
current_time = GetTickCount64() * 10000;
Module: wine
Branch: master
Commit: 6e4d441ce11739b145dae200d7b20743c64147de
URL: https://source.winehq.org/git/wine.git/?a=commit;h=6e4d441ce11739b145dae200…
Author: Zebediah Figura <z.figura12(a)gmail.com>
Date: Wed Jan 1 12:14:13 2020 -0600
user32/tests: Work around a failure on Windows < Vista.
Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com>
Signed-off-by: Alexandre Julliard <julliard(a)winehq.org>
---
dlls/user32/tests/winstation.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/dlls/user32/tests/winstation.c b/dlls/user32/tests/winstation.c
index aaa51d560a..4aa5565b96 100644
--- a/dlls/user32/tests/winstation.c
+++ b/dlls/user32/tests/winstation.c
@@ -51,7 +51,12 @@ static void register_class(void)
WNDCLASSA cls;
cls.style = CS_DBLCLKS;
- cls.lpfnWndProc = DefWindowProcA;
+ /* Windows < Vista apparently checks lpfnWndProc against the address of
+ * DefWindowProcA(), and for some reason fails to change the thread desktop
+ * after creating and destroying a window if it doesn't match. Using an IAT
+ * (as is default) or a wrapper triggers this, so use GetProcAddress() as
+ * a workaround. */
+ cls.lpfnWndProc = (void *)GetProcAddress(GetModuleHandleA("user32"), "DefWindowProcA");
cls.cbClsExtra = 0;
cls.cbWndExtra = 0;
cls.hInstance = GetModuleHandleA(0);