From 267c7407234157453157123599c35f07df71820f Mon Sep 17 00:00:00 2001 From: Shivam Mathur Date: Fri, 30 Oct 2026 09:17:46 +0530 Subject: [PATCH] Fix calling conventions in Windows alertable sleep test Place __stdcall outside the function-pointer parentheses, where FFI applies it to the function type. The nested placement is ignored and creates a cdecl APC callback, corrupting the Windows dispatcher stack on x86. --- .../tests/general_functions/sleep_alertable_win32.phpt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ext/standard/tests/general_functions/sleep_alertable_win32.phpt b/ext/standard/tests/general_functions/sleep_alertable_win32.phpt index 55da154ccf75..33e08ed844b0 100644 --- a/ext/standard/tests/general_functions/sleep_alertable_win32.phpt +++ b/ext/standard/tests/general_functions/sleep_alertable_win32.phpt @@ -19,10 +19,10 @@ $kernel32 = FFI::cdef(<<cast('GetCurrentThread_t', $kernel32->GetCurrentThread); $QueueUserAPC = $ffi->cast('QueueUserAPC_t', $kernel32->QueueUserAPC);