Skip to content

Commit

Permalink
Remove unnecessary write in StartOperationCommon
Browse files Browse the repository at this point in the history
We only need to update the socket if it's changed.
  • Loading branch information
stephentoub committed Jun 14, 2017
1 parent ccc7034 commit 6a1e1b0
Showing 1 changed file with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -455,6 +455,7 @@ internal void StartOperationCommon(Socket socket)
if (_completedChanged || socket != _currentSocket)
{
_completedChanged = false;
_currentSocket = socket;
_context = null;
}

Expand All @@ -463,9 +464,6 @@ internal void StartOperationCommon(Socket socket)
{
_context = ExecutionContext.Capture();
}

// Remember current socket.
_currentSocket = socket;
}

internal void StartOperationAccept()
Expand Down

0 comments on commit 6a1e1b0

Please sign in to comment.