mp_ringbuffer: use av_malloc for internal buffer