Flush even before we get end of message

This commit is contained in:
David Fowler 2016-10-07 01:06:04 -07:00
parent bbecb0c0dc
commit eef2f14c78
1 changed files with 4 additions and 7 deletions

View File

@ -54,14 +54,11 @@ namespace Microsoft.AspNetCore.Sockets
{
outputBuffer.Advance(result.Count);
if (result.EndOfMessage)
{
// Flush when we get an entire message
await outputBuffer.FlushAsync();
// Flush the written data to the channel
await outputBuffer.FlushAsync();
// Allocate a new buffer to further writing
outputBuffer = _channel.Input.Alloc();
}
// Allocate a new buffer to further writing
outputBuffer = _channel.Input.Alloc();
}
else
{