[vlc-commits] opengl: fix leak on error
Zhao Zhili
git at videolan.org
Wed Apr 18 14:50:26 CEST 2018
vlc | branch: master | Zhao Zhili <quinkblack at foxmail.com> | Wed Apr 18 20:43:49 2018 +0800| [e235d31e5b36eea6547f8e72af8836ac81f5887a] | committer: Thomas Guillem
opengl: fix leak on error
Signed-off-by: Thomas Guillem <thomas at gllm.fr>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=e235d31e5b36eea6547f8e72af8836ac81f5887a
---
modules/video_output/opengl/vout_helper.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/modules/video_output/opengl/vout_helper.c b/modules/video_output/opengl/vout_helper.c
index 2bf4f815bd..7b988de67e 100644
--- a/modules/video_output/opengl/vout_helper.c
+++ b/modules/video_output/opengl/vout_helper.c
@@ -649,7 +649,10 @@ opengl_init_program(vout_display_opengl_t *vgl, struct prgm *prgm,
vlc_fourcc_GetChromaDescription(fmt->i_chroma);
if (desc == NULL)
+ {
+ vlc_object_release(tc);
return VLC_EGENERIC;
+ }
if (desc->plane_count == 0)
{
/* Opaque chroma: load a module to handle it */
More information about the vlc-commits
mailing list