From adb4a099c83ea84c65e8d72ed7efdcf09c44d366 Mon Sep 17 00:00:00 2001 From: Nikolay Edigaryev Date: Mon, 19 May 2025 16:18:12 +0200 Subject: [PATCH] defer ptmx.Close() --- internal/rpc/exec.go | 1 + 1 file changed, 1 insertion(+) diff --git a/internal/rpc/exec.go b/internal/rpc/exec.go index 6dc47a0..4e3430e 100644 --- a/internal/rpc/exec.go +++ b/internal/rpc/exec.go @@ -53,6 +53,7 @@ func (rpc *RPC) Exec(stream grpc.BidiStreamingServer[ExecRequest, ExecResponse]) Rows: uint16(firstExecRequestCommand.Command.GetTerminalSize().GetRows()), Cols: uint16(firstExecRequestCommand.Command.GetTerminalSize().GetCols()), }) + defer ptmx.Close() if firstExecRequestCommand.Command.Interactive { stdin = ptmx