diff options
Diffstat (limited to 'libvo')
-rw-r--r-- | libvo/vo_vdpau.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libvo/vo_vdpau.c b/libvo/vo_vdpau.c index 26d643f42a..a179caec96 100644 --- a/libvo/vo_vdpau.c +++ b/libvo/vo_vdpau.c @@ -1111,10 +1111,18 @@ static void DestroyVdpauObjects(void) static void uninit(void) { + int i; + if (!vo_config_count) return; visible_buf = 0; + for (i = 0; i < MAX_VIDEO_SURFACES; i++) { + // Allocated in ff_vdpau_add_data_chunk() + av_freep(&surface_render[i].bitstream_buffers); + surface_render[i].bitstream_buffers_allocated = 0; + } + /* Destroy all vdpau objects */ DestroyVdpauObjects(); |