From 6a5205e9a1b835db6b071961e0ecb8fa0a2b2673 Mon Sep 17 00:00:00 2001 From: Administrator Date: Thu, 11 Nov 2021 02:22:14 +0800 Subject: [PATCH] 1 --- kiri-engine/Pool/Pool.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/kiri-engine/Pool/Pool.php b/kiri-engine/Pool/Pool.php index 1efb94af..5354e2c1 100644 --- a/kiri-engine/Pool/Pool.php +++ b/kiri-engine/Pool/Pool.php @@ -220,9 +220,12 @@ class Pool extends Component return; } while (static::$_connections[$name]->length() > 0) { - if (!Context::inCoroutine() && static::$_connections[$name] instanceof Channel) + if (static::$_connections[$name] instanceof Channel) { - break; + if (!Context::inCoroutine()) + { + break; + } } $client = static::$_connections[$name]->pop(); if ($client instanceof StopHeartbeatCheck) {