1
0
mirror of https://github.com/php/php-src.git synced 2026-03-24 00:02:20 +01:00

[win32] Use RETURN_BOOL() in sapi_windows_set_ctrl_handler() (GH-21148)

This commit is contained in:
Arshid
2026-02-06 14:39:40 +05:30
committed by GitHub
parent f0d321e947
commit 51158bbe90

View File

@@ -131,10 +131,7 @@ PHP_FUNCTION(sapi_windows_set_ctrl_handler)
if (!ZEND_FCI_INITIALIZED(fci)) {
zval_ptr_dtor(&ctrl_handler);
ZVAL_UNDEF(&ctrl_handler);
if (!SetConsoleCtrlHandler(NULL, add)) {
RETURN_FALSE;
}
RETURN_TRUE;
RETURN_BOOL(SetConsoleCtrlHandler(NULL, add));
}
if (!SetConsoleCtrlHandler(NULL, FALSE) || !SetConsoleCtrlHandler(php_win32_signal_system_ctrl_handler, add)) {