mirror of
https://github.com/mpv-player/mpv
synced 2025-02-05 22:52:18 +00:00
Avoid decoding of 0-size packets. This also fixes that the main loop believes
tehre is an infinite number of delayed frames, thus never finishing (happens with -demuxer lavf -vc theora). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31206 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
4ad8b9e0cc
commit
9016e5cf0a
@ -168,6 +168,10 @@ static mp_image_t* decode(sh_video_t *sh,void* data,int len,int flags)
|
||||
yuv_buffer yuv;
|
||||
mp_image_t* mpi;
|
||||
|
||||
// no delayed frames
|
||||
if (!data || !len)
|
||||
return NULL;
|
||||
|
||||
memset (&op, 0, sizeof (op));
|
||||
op.bytes = len;
|
||||
op.packet = data;
|
||||
|
Loading…
Reference in New Issue
Block a user