From 6b11ba8286576d0a99dffc39a66b6efd925c604d Mon Sep 17 00:00:00 2001 From: mockingjay <8400684@qq.com> Date: Sat, 11 May 2024 10:13:16 +0800 Subject: [PATCH] fix bus --- src/SuperSocket.Connection/PipeConnectionBase.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/SuperSocket.Connection/PipeConnectionBase.cs b/src/SuperSocket.Connection/PipeConnectionBase.cs index d390ddc15..cba380d7a 100644 --- a/src/SuperSocket.Connection/PipeConnectionBase.cs +++ b/src/SuperSocket.Connection/PipeConnectionBase.cs @@ -82,7 +82,12 @@ public async override IAsyncEnumerable RunAsync(IPip { var package = await packagePipe.ReadAsync().ConfigureAwait(false); - e + if (package == null) + { + yield break; + } + + yield return package; } //How do empty a pipe?