From 8ba61eaced20ce138bfb112e140b2067f65e938d Mon Sep 17 00:00:00 2001 From: Masahide Yamasaki Date: Sat, 26 Oct 2024 16:14:16 +0900 Subject: [PATCH] fix --- cmd/wsl2-ssh-agent-proxy/pwsh.ps1 | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cmd/wsl2-ssh-agent-proxy/pwsh.ps1 b/cmd/wsl2-ssh-agent-proxy/pwsh.ps1 index 15dc8e1..d1d11a1 100644 --- a/cmd/wsl2-ssh-agent-proxy/pwsh.ps1 +++ b/cmd/wsl2-ssh-agent-proxy/pwsh.ps1 @@ -75,7 +75,10 @@ $PacketWorkerScript = { } catch { [Console]::Error.WriteLine("PacketWorker [ch:$($Packet.channelID) type:$($Packet.TypeNum)]: Exception occurred while processing. Error: $($_.Exception.Message). Worker will stop.") + $this.NamedPipeStream.Close() + $this.NamedPipeStream = $null $this.StopWorker($Packet.ChannelID) + Start-Sleep -Seconds 1.0 continue } }