[PATCH 0/1] MR3008: mmdevapi: Handle CreateThread() failure in AudioClient's Start.
From: Davide Beatrici <git(a)davidebeatrici.dev> --- dlls/mmdevapi/client.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/dlls/mmdevapi/client.c b/dlls/mmdevapi/client.c index 9755dd2d8ef..d9c563a00d0 100644 --- a/dlls/mmdevapi/client.c +++ b/dlls/mmdevapi/client.c @@ -228,8 +228,12 @@ HRESULT WINAPI client_Start(IAudioClient3 *iface) WINE_UNIX_CALL(start, ¶ms); if (SUCCEEDED(params.result) && !This->timer_thread) { - This->timer_thread = CreateThread(NULL, 0, timer_loop_func, This, 0, NULL); - SetThreadPriority(This->timer_thread, THREAD_PRIORITY_TIME_CRITICAL); + if ((This->timer_thread = CreateThread(NULL, 0, timer_loop_func, This, 0, NULL))) + SetThreadPriority(This->timer_thread, THREAD_PRIORITY_TIME_CRITICAL); + else { + IAudioClient3_Stop(&This->IAudioClient3_iface); + params.result = E_FAIL; + } } sessions_unlock(); -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/3008
Hi, It looks like your patch introduced the new failures shown below. Please investigate and fix them before resubmitting your patch. If they are not new, fixing them anyway would help a lot. Otherwise please ask for the known failures list to be updated. The full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=133555 Your paranoid android. === debian11 (build log) === error: patch failed: dlls/mmdevapi/client.c:228 Task: Patch failed to apply === debian11b (build log) === error: patch failed: dlls/mmdevapi/client.c:228 Task: Patch failed to apply
This merge request was approved by Huw Davies. -- https://gitlab.winehq.org/wine/wine/-/merge_requests/3008
participants (4)
-
Davide Beatrici -
Davide Beatrici (@davidebeatrici) -
Huw Davies (@huw) -
Marvin