[MPlayer-cvslog] r23772 - trunk/libmpdemux/video.c

attila subversion at mplayerhq.hu
Fri Jul 13 16:39:18 CEST 2007


Author: attila
Date: Fri Jul 13 16:39:18 2007
New Revision: 23772

Log:
Fix segfault if an 'strf' chunk couldn't be found in avi


Modified:
   trunk/libmpdemux/video.c

Modified: trunk/libmpdemux/video.c
==============================================================================
--- trunk/libmpdemux/video.c	(original)
+++ trunk/libmpdemux/video.c	Fri Jul 13 16:39:18 2007
@@ -85,6 +85,9 @@ switch(video_codec){
  case VIDEO_OTHER: {
  if((d_video->demuxer->file_format == DEMUXER_TYPE_ASF) || (d_video->demuxer->file_format == DEMUXER_TYPE_AVI)) {
   // display info: 
+       // in case no strf chunk has been seen in avi, we have no bitmap header
+       if(!sh_video->bih) return 0;
+
         sh_video->format=sh_video->bih->biCompression;
 
     sh_video->disp_w=sh_video->bih->biWidth;



More information about the MPlayer-cvslog mailing list