Skip to content

Commit

Permalink
Dispose old socket again
Browse files Browse the repository at this point in the history
  • Loading branch information
ShortDevelopment committed Jan 1, 2025
1 parent d3f901c commit 2ef06a1
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,9 @@ async void PrepareSession(CdpSocket socket)
{
try
{
socket = await _clientUpgradeHandler.UpgradeAsync(socket);
var oldSocket = socket;
socket = await _clientUpgradeHandler.UpgradeAsync(oldSocket);
oldSocket.Dispose();
}
catch (Exception ex)
{
Expand Down

0 comments on commit 2ef06a1

Please sign in to comment.