mirror of
https://github.com/dotnet/MQTTnet.git
synced 2026-10-16 09:13:02 +08:00
changed waiting condition
This commit is contained in:
@@ -222,7 +222,7 @@ namespace MQTTnet.Client
|
||||
|
||||
try
|
||||
{
|
||||
if (!(exception is MqttCommunicationClosedGracefullyException))
|
||||
if (clientWasConnected)
|
||||
{
|
||||
await WaitForTaskAsync(_packetReceiverTask, sender).ConfigureAwait(false);
|
||||
await WaitForTaskAsync(_keepAliveMessageSenderTask, sender).ConfigureAwait(false);
|
||||
|
||||
Reference in New Issue
Block a user