Skip to content

Commit 502c2cd

Browse files
authored
doc(MockSocket): update mock socket sample (#7704)
1 parent 5b19fb2 commit 502c2cd

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/BootstrapBlazor.Server/Services/MockDisconnectService.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Licensed to the .NET Foundation under one or more agreements.
1+
// Licensed to the .NET Foundation under one or more agreements.
22
// The .NET Foundation licenses this file to you under the Apache 2.0 License
33
// See the LICENSE file in the project root for more information.
44
// Maintainer: Argo Zhang(argo@live.ca) Website: https://www.blazor.zone
@@ -54,6 +54,7 @@ private async Task OnDataHandlerAsync(TcpClient client, CancellationToken stoppi
5454
catch (OperationCanceledException) { break; }
5555
catch (IOException) { break; }
5656
catch (SocketException) { break; }
57+
catch (ObjectDisposedException) { break; }
5758
catch (Exception ex)
5859
{
5960
logger.LogError(ex, "MockDisconnectServerService encountered an error while sending data.");

0 commit comments

Comments
 (0)