From 915b869e3fc6377be114c033763987de612c443c Mon Sep 17 00:00:00 2001 From: Robin Jarry Date: Fri, 6 Jan 2023 22:49:26 +0100 Subject: lint: add missing panic handlers in goroutines These issues were all reported by the new custom analyzer introduced in previous commit. Signed-off-by: Robin Jarry Tested-by: Bence Ferdinandy --- commands/msgview/open.go | 2 ++ 1 file changed, 2 insertions(+) (limited to 'commands/msgview/open.go') diff --git a/commands/msgview/open.go b/commands/msgview/open.go index 1b9efb38..0380b51a 100644 --- a/commands/msgview/open.go +++ b/commands/msgview/open.go @@ -7,6 +7,7 @@ import ( "os" "git.sr.ht/~rjarry/aerc/lib" + "git.sr.ht/~rjarry/aerc/log" "git.sr.ht/~rjarry/aerc/widgets" ) @@ -57,6 +58,7 @@ func (Open) Execute(aerc *widgets.Aerc, args []string) error { } go func() { + defer log.PanicHandler() err = lib.XDGOpenMime(tmpFile.Name(), mimeType, args[1:]) if err != nil { aerc.PushError("open: " + err.Error()) -- cgit