Skip to content

Commit

Permalink
fix: -connect_relay unable to recovery SSH session
Browse files Browse the repository at this point in the history
`ctx` got canceled in previous session
  • Loading branch information
jm33-m0 committed Jan 16, 2024
1 parent d78cabd commit 8bde2fb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/cmd/cc/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,6 @@ func main() {
if *relayed_port == 0 {
cc.CliFatalError("Please specify -relayed_port")
}
ctx, cancel := context.WithCancel(context.Background())
go func() {
defer cc.CliPrintError("session unexpectedly exited, please restart emp3r0r")
var SSHConnections = make(map[string]context.CancelFunc, 10)
Expand All @@ -148,6 +147,7 @@ func main() {
cc.CliFatalError("Parsing SSHPublicKey: %v", err)
}
ssh_connect:
ctx, cancel := context.WithCancel(context.Background())
err = tun.SSHRemoteFwdClient(*connect_relay_addr,
cc.RuntimeConfig.ShadowsocksPassword,
pubkey,
Expand Down

0 comments on commit 8bde2fb

Please sign in to comment.