Fix golangci-lint errcheck and unused errors
CI / test (push) Failing after 12m57s

- manager.go: add _ = to syscall.Kill and proc.Signal calls (6 fixes)
- chat.go: add _ = to c.Writer.WriteString calls (9 fixes)
- webhook.go: remove unused webhookSecret field
This commit is contained in:
2026-07-30 17:20:34 -04:00
parent e9c81f7c30
commit f775c2f67e
3 changed files with 17 additions and 18 deletions
+6 -6
View File
@@ -92,14 +92,14 @@ func (m *Manager) Stop() {
pgid, err := syscall.Getpgid(m.proc.Process.Pid)
if err == nil {
syscall.Kill(-pgid, syscall.SIGTERM)
_ = syscall.Kill(-pgid, syscall.SIGTERM)
} else {
m.proc.Process.Signal(syscall.SIGTERM)
_ = m.proc.Process.Signal(syscall.SIGTERM)
}
<-ctx.Done()
if m.proc.ProcessState == nil {
syscall.Kill(-pgid, syscall.SIGKILL)
_ = syscall.Kill(-pgid, syscall.SIGKILL)
}
}
@@ -256,9 +256,9 @@ func (m *Manager) terminateProcess() {
pgid, err := syscall.Getpgid(m.proc.Process.Pid)
if err == nil {
syscall.Kill(-pgid, syscall.SIGTERM)
_ = syscall.Kill(-pgid, syscall.SIGTERM)
} else {
m.proc.Process.Signal(syscall.SIGTERM)
_ = m.proc.Process.Signal(syscall.SIGTERM)
}
done := make(chan error, 1)
@@ -269,7 +269,7 @@ func (m *Manager) terminateProcess() {
select {
case <-ctx.Done():
if pgid, err := syscall.Getpgid(m.proc.Process.Pid); err == nil {
syscall.Kill(-pgid, syscall.SIGKILL)
_ = syscall.Kill(-pgid, syscall.SIGKILL)
}
case <-done:
}