提交 3ca1dd35 编写于 作者: A aarzilli

cmd/dlv: bugfix: trace disables terminal echo

Fixes #397
上级 09451707
......@@ -256,7 +256,9 @@ func traceCmd(cmd *cobra.Command, args []string) {
}
cmds := terminal.DebugCommands(client)
cmd := cmds.Find("continue")
err = cmd(terminal.New(client, nil), "")
t := terminal.New(client, nil)
defer t.Close()
err = cmd(t, "")
if err != nil {
fmt.Fprintln(os.Stderr, err)
return 1
......
......@@ -41,9 +41,13 @@ func New(client service.Client, conf *config.Config) *Term {
}
}
func (t *Term) Close() {
t.line.Close()
}
// Run begins running dlv in the terminal.
func (t *Term) Run() (int, error) {
defer t.line.Close()
defer t.Close()
// Send the debugger a halt command on SIGINT
ch := make(chan os.Signal)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册