[MPlayer-cvslog] r37666 - trunk/libmpcodecs/vd_mpegpes.c

reimar subversion at mplayerhq.hu
Wed Feb 10 23:16:58 CET 2016


Author: reimar
Date: Wed Feb 10 23:16:57 2016
New Revision: 37666

Log:
vd_mpegpes.c: Add allocation failure check.

Fixes Coverity warning.

Modified:
   trunk/libmpcodecs/vd_mpegpes.c

Modified: trunk/libmpcodecs/vd_mpegpes.c
==============================================================================
--- trunk/libmpcodecs/vd_mpegpes.c	Wed Feb 10 23:14:33 2016	(r37665)
+++ trunk/libmpcodecs/vd_mpegpes.c	Wed Feb 10 23:16:57 2016	(r37666)
@@ -77,6 +77,7 @@ static mp_image_t* decode(sh_video_t *sh
     }
 
     mpi=mpcodecs_get_image(sh, MP_IMGTYPE_EXPORT, 0, sh->disp_w, sh->disp_h);
+    if (!mpi) return 0;
     packet.data=data;
     packet.size=len;
     packet.timestamp=sh->timer*90000.0;


More information about the MPlayer-cvslog mailing list