From 94c33ac020fd7e846073cabffa5cf13386f3c852 Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Sat, 15 Jun 2024 10:23:03 +0900 Subject: [PATCH] Fix panic when parent process is killed Fix #3863 --- main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main.go b/main.go index d853681..f32813d 100644 --- a/main.go +++ b/main.go @@ -39,7 +39,7 @@ func printScript(label string, content []byte) { } func exit(code int, err error) { - if code == fzf.ExitError { + if code == fzf.ExitError && err != nil { fmt.Fprintln(os.Stderr, err.Error()) } os.Exit(code)