utils.RingBuffer: Avoid blocking in .read() when buffer is closed.
stream.hls: Wait for filler thread to exit in .close().