workerman/http-client 经常报错,无规律,找不到原因。

0
21-06-02 12:24:19 pid:18027 Error: Call to a member function destroy() on null in /data/wwwroot/project/vendor/workerman/http-client/src/Request.php:453
Stack trace:
#0 /data/wwwroot/project/vendor/workerman/http-client/src/Request.php(431): Workerman\Http\Request->emitError(Object(think\exception\ErrorException))
#1 /data/wwwroot/project/vendor/workerman/http-client/src/Request.php(428): Workerman\Http\Request->handleChunkedData(Object(Workerman\Connection\AsyncTcpConnection), '')
#2 /data/wwwroot/project/vendor/workerman/http-client/src/Request.php(420): Workerman\Http\Request->handleChunkedData(Object(Workerman\Connection\AsyncTcpConnection), '')
#3 /data/wwwroot/project/vendor/workerman/http-client/src/Request.php(349): Workerman\Http\Request->handleChunkedData(Object(Workerman\Connection\AsyncTcpConnection), '233\r\n{"msg":"SU...')
#4 /data/wwwroot/project/vendor/workerman/http-client/src/Request.php(326): Workerman\Http\Request->checkComplete('233\r\n{"msg":"SU...')
#5 /data/wwwroot/project/vendor/workerman/workerman/Connection/TcpConnection.php(660): Workerman\Http\Request->onMessage(Object(Workerman\Connection\AsyncTcpConnection), 'HTTP/1.1 200 \r\n...')
#6 [internal function]: Workerman\Connection\TcpConnection->baseRead(Resource id #246, 2, Resource id #246)
#7 /data/wwwroot/project/vendor/workerman/workerman/Events/Event.php(195): EventBase->loop()
#8 /data/wwwroot/project/vendor/workerman/workerman/Worker.php(2430): Workerman\Events\Event->loop()
#9 /data/wwwroot/project/vendor/workerman/workerman/Worker.php(1554): Workerman\Worker->run()
#10 /data/wwwroot/project/vendor/workerman/workerman/Worker.php(1384): Workerman\Worker::forkOneWorkerForLinux(Object(Workerman\Worker))
#11 /data/wwwroot/project/vendor/workerman/workerman/Worker.php(1358): Workerman\Worker::forkWorkersForLinux()
#12 /data/wwwroot/project/vendor/workerman/workerman/Worker.php(542): Workerman\Worker::forkWorkers()
#13 /data/wwwroot/project/app/workerman/command/Worker.php(65): Workerman\Worker::runAll()
#14 /data/wwwroot/project/vendor/topthink/framework/src/think/console/Command.php(210): app\workerman\command\Worker->execute(Object(think\console\Input), Object(think\console\Output))
#15 /data/wwwroot/project/vendor/topthink/framework/src/think/Console.php(655): think\console\Command->run(Object(think\console\Input), Object(think\console\Output))
#16 /data/wwwroot/project/vendor/topthink/framework/src/think/Console.php(314): think\Console->doRunCommand(Object(app\workerman\command\Worker), Object(think\console\Input), Object(think\console\Output))
#17 /data/wwwroot/project/vendor/topthink/framework/src/think/Console.php(251): think\Console->doRun(Object(think\console\Input), Object(think\console\Output))
#18 /data/wwwroot/project/think(10): think\Console->run()
#19 {main}
2021-06-02 12:24:19 pid:18027 Worker[18027] process terminated
2021-06-02 12:24:19 pid:18015 worker[Webserver:18027] exit with status 64000
已邀请:

latin - 挨踢男

赞同来自:

改下源码,判断下 是不是null,是null就不执行destroy()

要回复问题请先登录注册