Skip to content

Commit 86b89e8

Browse files
committed
sends the signal to the calling process's process group
using previous methods SIGSTOP was only being sent to lazygit's process this way calling process's get sent SIGSTOP.
1 parent 5bf82cc commit 86b89e8

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

pkg/gui/gui.go

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -447,11 +447,7 @@ func (gui *Gui) suspendApp(g *gocui.Gui, v *gocui.View) error {
447447

448448
gui.BackgroundRoutineMgr.PauseBackgroundRefreshes(true)
449449

450-
p, err := os.FindProcess(os.Getpid())
451-
if err != nil {
452-
return err
453-
}
454-
return p.Signal(syscall.SIGTSTP)
450+
return syscall.Kill(0, syscall.SIGSTOP)
455451
}
456452

457453
func (gui *Gui) handleResume(g *gocui.Gui) {

0 commit comments

Comments
 (0)