vlc | branch: master | Steve Lhomme <[email protected]> | Mon Nov 25 16:32:40 
2019 +0100| [e5276162af7a387197efe5b2670ce99df3d9a184] | committer: Steve Lhomme

avcodec: vdpau: don't destroy surfaces twice in case of error

They will be destroyed in DestroyVDPAUVideoContext when the video context is
destroyed on error. Just like they are destroyed when the video context is
destroyed in the normal case.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=e5276162af7a387197efe5b2670ce99df3d9a184
---

 modules/hw/vdpau/avcodec.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/modules/hw/vdpau/avcodec.c b/modules/hw/vdpau/avcodec.c
index 74aa135f70..66c40de488 100644
--- a/modules/hw/vdpau/avcodec.c
+++ b/modules/hw/vdpau/avcodec.c
@@ -256,8 +256,6 @@ static int Open(vlc_va_t *va, AVCodecContext *avctx, const 
AVPixFmtDescriptor *d
     if (i < refs)
     {
         msg_Err(va, "not enough video RAM");
-        while (i > 0)
-            vlc_vdp_video_destroy(vctx_priv->pool[--i]);
         goto error;
     }
 

_______________________________________________
vlc-commits mailing list
[email protected]
https://mailman.videolan.org/listinfo/vlc-commits

Reply via email to