From 3c8edb08af84fc41fbe8b75828300d192ce27c6c Mon Sep 17 00:00:00 2001 From: youngkin Date: Wed, 1 Dec 2021 18:40:42 +0000 Subject: [PATCH] fix bug caused by running without sudo --- pwmdemo/pwmexplorer/main.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pwmdemo/pwmexplorer/main.go b/pwmdemo/pwmexplorer/main.go index 6b579a2..eecb0ba 100644 --- a/pwmdemo/pwmexplorer/main.go +++ b/pwmdemo/pwmexplorer/main.go @@ -512,6 +512,8 @@ func getButtonForm(ui *tview.Application, pwmApp *PWMApp, msg *tview.TextView) * // } if err := syscall.Kill(-cmd.Process.Pid, syscall.SIGINT); err != nil { msg.SetText(fmt.Sprintf("Error sending interrupt signal: %s", err)) + running = false + return } running = false msg.SetText("Test stopped")