diff --git a/streamer.go b/streamer.go index 12e86cb..1eec96f 100644 --- a/streamer.go +++ b/streamer.go @@ -39,6 +39,7 @@ func encode(url string, w io.Writer) error { if err != nil { return err } + defer out.Close() err = cmd.Start() if err != nil {