[MPlayer-cvslog] r36543 - trunk/libmpdemux/demux_mpg.c

reimar subversion at mplayerhq.hu
Wed Dec 11 21:03:03 CET 2013


Author: reimar
Date: Wed Dec 11 21:03:03 2013
New Revision: 36543

Log:
Only detect a file as MPEG-PS if we can find at least 2 packets.

Modified:
   trunk/libmpdemux/demux_mpg.c

Modified: trunk/libmpdemux/demux_mpg.c
==============================================================================
--- trunk/libmpdemux/demux_mpg.c	Wed Dec 11 21:03:02 2013	(r36542)
+++ trunk/libmpdemux/demux_mpg.c	Wed Dec 11 21:03:03 2013	(r36543)
@@ -191,7 +191,8 @@ static demuxer_t* demux_mpg_open(demuxer
   stream_t *s = demuxer->stream;
   mpg_demuxer_t* mpg_d;
 
-  if (!ds_fill_buffer(demuxer->video)) return 0;
+  while (demuxer->video->packs + demuxer->audio->packs < 2)
+    if (!ds_fill_buffer(demuxer->video)) return 0;
   mpg_d = calloc(1,sizeof(mpg_demuxer_t));
   if(mpg_d)
   {


More information about the MPlayer-cvslog mailing list