This commit is contained in:
2020-10-09 17:39:42 +08:00
parent 188e282cb1
commit 6029e2cb7f
+4 -1
View File
@@ -417,7 +417,10 @@ class Socket
*/ */
protected function isSocketDead() protected function isSocketDead()
{ {
return !$this->stream instanceof \Swoole\Coroutine\Socket || !$this->stream->checkLiveness(); if (!($this->stream instanceof \Swoole\Coroutine\Socket)) {
return true;
}
return $this->stream->checkLiveness();
} }
// }}} // }}}