1
0
mirror of https://github.com/spl0k/supysonic.git synced 2024-12-22 17:06:17 +00:00

Kill transcoding processes on error

Asking nicely with a SIGTERM doesn't cause the transcoding process(es)
to exit. Using SIGKILL gets the job done.

This was verified by manually sending SIGTERM and SIGKILL signals to
hung transcoding processes, as well as getting a client to abort stream
requests before they had completed.

Fixes #55
This commit is contained in:
Carey Metcalfe 2018-10-12 02:37:59 -04:00
parent 9ab6af1ae6
commit 9ac30419ab

View File

@ -102,8 +102,8 @@ def stream_media():
yield data
except: # pragma: nocover
if dec_proc != None:
dec_proc.terminate()
proc.terminate()
dec_proc.kill()
proc.kill()
if dec_proc != None:
dec_proc.wait()