(context.Context)
| 660 | } |
| 661 | |
| 662 | func (t *ToolSet) Stop(context.Context) error { |
| 663 | // Terminate all running background jobs |
| 664 | t.handler.jobs.Range(func(_ string, job *backgroundJob) bool { |
| 665 | if job.status.CompareAndSwap(statusRunning, statusStopped) { |
| 666 | _ = kill(job.process, job.processGroup) |
| 667 | } |
| 668 | return true |
| 669 | }) |
| 670 | |
| 671 | // Tear down the sudo askpass helper (socket + wrapper script), if started. |
| 672 | t.handler.stopAskpass() |
| 673 | |
| 674 | return nil |
| 675 | } |
nothing calls this directly
no test coverage detected