[vlc-commits] input: decoder: fix potential NULL deref on transcoding

Francois Cartegnie git at videolan.org
Tue Feb 12 18:50:29 CET 2019


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Tue Feb 12 18:49:28 2019 +0100| [6309db13284b58dbaf00e3ce46cdcbcbad11eddb] | committer: Francois Cartegnie

input: decoder: fix potential NULL deref on transcoding

946b67f964396056caba8cb3b62bdf9a976abfae regression

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

 src/input/decoder.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/input/decoder.c b/src/input/decoder.c
index 855b4cc8d7..51b509dbad 100644
--- a/src/input/decoder.c
+++ b/src/input/decoder.c
@@ -1912,7 +1912,7 @@ static decoder_t * CreateDecoder( vlc_object_t *p_parent,
     switch( fmt->i_cat )
     {
         case VIDEO_ES:
-            if( !input_priv( p_input )->b_thumbnailing )
+            if( !p_input || !input_priv( p_input )->b_thumbnailing )
                 p_dec->cbs = &dec_video_cbs;
             else
                 p_dec->cbs = &dec_thumbnailer_cbs;



More information about the vlc-commits mailing list