[vlc-commits] interlacing: Fix leak on error
Hugo Beauzée-Luyssen
git at videolan.org
Mon Sep 4 12:03:43 CEST 2017
vlc | branch: master | Hugo Beauzée-Luyssen <hugo at beauzee.fr> | Sat Sep 2 18:23:44 2017 +0200| [7f6724eb9a2bb049bebfa2f247b769b445e3aa72] | committer: Hugo Beauzée-Luyssen
interlacing: Fix leak on error
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=7f6724eb9a2bb049bebfa2f247b769b445e3aa72
---
src/video_output/interlacing.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/src/video_output/interlacing.c b/src/video_output/interlacing.c
index 376e66d02b..f07ef8ef5a 100644
--- a/src/video_output/interlacing.c
+++ b/src/video_output/interlacing.c
@@ -73,7 +73,10 @@ static int DeinterlaceCallback(vlc_object_t *object, char const *cmd,
char *mode = var_GetString(vout, "deinterlace-mode");
const bool is_needed = var_GetBool(vout, "deinterlace-needed");
if (!mode || !DeinterlaceIsModeValid(mode))
+ {
+ free(mode);
return VLC_EGENERIC;
+ }
/* */
char *old = var_CreateGetString(vout, "sout-deinterlace-mode");
More information about the vlc-commits
mailing list