Update Util.php

This commit is contained in:
walkor 2023-05-03 10:38:43 +08:00 committed by GitHub
parent 92b1551284
commit af0167a44b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -519,7 +519,7 @@ class Util
/** /**
* reload webman (不支持windows) * reload webman
* @return bool * @return bool
*/ */
public static function reloadWebman() public static function reloadWebman()
@ -529,6 +529,10 @@ class Util
posix_kill(posix_getppid(), SIGUSR1); posix_kill(posix_getppid(), SIGUSR1);
return true; return true;
} catch (Throwable $e) {} } catch (Throwable $e) {}
} else {
Timer::add(1, function () {
Worker::stopAll();
});
} }
return false; return false;
} }