fix zombie process bug with Wait
This commit is contained in:
parent
257aae83bc
commit
6ebeab58ca
1 changed files with 3 additions and 2 deletions
5
main.go
5
main.go
|
|
@ -46,8 +46,9 @@ func (mpv *MPV) Spawn() error {
|
|||
return mpv.cmd.Start()
|
||||
}
|
||||
|
||||
func (mpv *MPV) Stop() error {
|
||||
return mpv.cmd.Process.Kill()
|
||||
func (mpv *MPV) Stop() {
|
||||
mpv.cmd.Process.Kill()
|
||||
mpv.cmd.Process.Wait()
|
||||
}
|
||||
|
||||
func (mpv *MPV) ExecuteIPC(req *MPVRequest) ([]byte, error) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue