Sfoglia il codice sorgente

Refactor task await.

release/3.x.x
Christian Kratky 6 anni fa
parent
commit
6fc9f12c34
1 ha cambiato i file con 2 aggiunte e 2 eliminazioni
  1. +2
    -2
      Source/MQTTnet.AspnetCore/MqttConnectionContext.cs

+ 2
- 2
Source/MQTTnet.AspnetCore/MqttConnectionContext.cs Vedi File

@@ -62,7 +62,7 @@ namespace MQTTnet.AspNetCore
}
else
{
readResult = await readTask;
readResult = await readTask.ConfigureAwait(false);
}

var buffer = readResult.Buffer;
@@ -115,7 +115,7 @@ namespace MQTTnet.AspNetCore
await _writerSemaphore.WaitAsync(cancellationToken).ConfigureAwait(false);
try
{
await output.WriteAsync(buffer, cancellationToken);
await output.WriteAsync(buffer, cancellationToken).ConfigureAwait(false);
}
finally
{


Caricamento…
Annulla
Salva