Skip to content

Commit

Permalink
Lint fix
Browse files Browse the repository at this point in the history
  • Loading branch information
makew0rld committed Dec 23, 2021
1 parent 034b4c0 commit d312a80
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 0 deletions.
2 changes: 2 additions & 0 deletions display/download.go
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,7 @@ func open(u string, resp *gemini.Response) {
Error("File Opening Error", "Error executing custom command: "+err.Error())
return
}
//nolint:errcheck
go proc.Wait() // Prevent zombies, see #219
Info("Opened with " + cmd[0])
return
Expand Down Expand Up @@ -221,6 +222,7 @@ func open(u string, resp *gemini.Response) {
Error("File Opening Error", "Error executing custom command: "+err.Error())
return
}
//nolint:errcheck
go proc.Wait() // Prevent zombies, see #219
Info("Opened with " + cmd[0])
}
Expand Down
2 changes: 2 additions & 0 deletions display/handlers.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ func handleHTTP(u string, showInfo bool) bool {
Error("HTTP Error", "Error executing custom browser command: "+err.Error())
return false
}
//nolint:errcheck
go proc.Wait() // Prevent zombies, see #219
Info("Opened with: " + config.HTTPCommand[0])

Expand Down Expand Up @@ -116,6 +117,7 @@ func handleOther(u string) {
if err != nil {
Error("URL Error", "Error executing custom command: "+err.Error())
}
//nolint:errcheck
go proc.Wait() // Prevent zombies, see #219
Info("Opened with: " + handler[0])
App.Draw()
Expand Down
1 change: 1 addition & 0 deletions sysopen/open_browser_darwin.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ func Open(path string) (string, error) {
if err != nil {
return "", err
}
//nolint:errcheck
go proc.Wait() // Prevent zombies, see #219
return "Opened in default system viewer", nil
}
1 change: 1 addition & 0 deletions sysopen/open_browser_unix.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ func Open(path string) (string, error) {
if err := proc.Start(); err != nil {
return "", err
}
//nolint:errcheck
go proc.Wait() // Prevent zombies, see #219
return "Opened in default system viewer", nil
default:
Expand Down
1 change: 1 addition & 0 deletions sysopen/open_browser_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ func Open(path string) (string, error) {
if err != nil {
return "", err
}
//nolint:errcheck
go proc.Wait() // Prevent zombies, see #219
return "Opened in default system viewer", nil
}
1 change: 1 addition & 0 deletions webbrowser/open_browser_darwin.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ func Open(url string) (string, error) {
if err != nil {
return "", err
}
//nolint:errcheck
go proc.Wait() // Prevent zombies, see #219
return "Opened in system default web browser", nil
}
2 changes: 2 additions & 0 deletions webbrowser/open_browser_unix.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,13 +38,15 @@ func Open(url string) (string, error) {
if err := proc.Start(); err != nil {
return "", err
}
//nolint:errcheck
go proc.Wait() // Prevent zombies, see #219
return "Opened in system default web browser", nil
case envBrowser != "":
proc := exec.Command(envBrowser, url)
if err := proc.Start(); err != nil {
return "", err
}
//nolint:errcheck
go proc.Wait() // Prevent zombies, see #219
return "Opened in system default web browser", nil
default:
Expand Down
1 change: 1 addition & 0 deletions webbrowser/open_browser_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ func Open(url string) (string, error) {
if err != nil {
return "", err
}
//nolint:errcheck
go proc.Wait() // Prevent zombies, see #219
return "Opened in system default web browser", nil
}

0 comments on commit d312a80

Please sign in to comment.