You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
在liunx下执行命令出错
报错1:执行php think hello start --mode d
Implicit conversion from float 2999991.1785125732 to int loses precision
解决:Workerman\Events\Select::class -> loop() 274行_selectTimeout属性传递到usleep(int)函数精度问题导致,使用int强转一下 usleep((int)$this->_selectTimeout)
报错2:fclose(): Argument #1 ($stream) must be of type resource, null given
解决:vendor/workerman/workerman/Worker.php,1245-1248行的fclose()函数加上判断
if ($STDOUT) {
\fclose($STDOUT);
}
if ($STDERR) {
\fclose($STDERR);
}
if (is_resource(\STDOUT)) {
\fclose(\STDOUT);
}
if (is_resource(\STDERR)) {
\fclose(\STDERR);
}
希望尽快提高workerman的版本,并修改部分代码,谢谢~~~
The text was updated successfully, but these errors were encountered:
框架版本:thinkphp8
php版本:>=php8.0
在liunx下执行命令出错
报错1:执行php think hello start --mode d
Implicit conversion from float 2999991.1785125732 to int loses precision
解决:Workerman\Events\Select::class -> loop() 274行_selectTimeout属性传递到usleep(int)函数精度问题导致,使用int强转一下 usleep((int)$this->_selectTimeout)
报错2:fclose(): Argument #1 ($stream) must be of type resource, null given
解决:vendor/workerman/workerman/Worker.php,1245-1248行的fclose()函数加上判断
if ($STDOUT) {
\fclose($STDOUT);
}
if ($STDERR) {
\fclose($STDERR);
}
if (is_resource(\STDOUT)) {
\fclose(\STDOUT);
}
if (is_resource(\STDERR)) {
\fclose(\STDERR);
}
希望尽快提高workerman的版本,并修改部分代码,谢谢~~~
The text was updated successfully, but these errors were encountered: