diff options
author | nicodvb <nicodvb@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2006-04-05 20:51:35 +0000 |
---|---|---|
committer | nicodvb <nicodvb@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2006-04-05 20:51:35 +0000 |
commit | ecdfed51225db0ed2237661001274e91edd23617 (patch) | |
tree | fe41c3d9a705ef4924010768703e18200e69d05f /libmpdemux/muxer_mpeg.c | |
parent | 7d8d00765081e891428cf872ccedbbbd598c6f5c (diff) | |
download | mpv-ecdfed51225db0ed2237661001274e91edd23617.tar.bz2 mpv-ecdfed51225db0ed2237661001274e91edd23617.tar.xz |
workaround to prevent segfault: when using -ve lavc with b-frames write_chunk(1st video frame) gets called with len=-1UL; -1ULl to whomever calls me that way
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@18045 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpdemux/muxer_mpeg.c')
-rw-r--r-- | libmpdemux/muxer_mpeg.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libmpdemux/muxer_mpeg.c b/libmpdemux/muxer_mpeg.c index abcc28c75c..7f03f0ff66 100644 --- a/libmpdemux/muxer_mpeg.c +++ b/libmpdemux/muxer_mpeg.c @@ -2436,6 +2436,8 @@ static void mpegfile_write_chunk(muxer_stream_t *s,size_t len,unsigned int flags if(s->buffer == NULL) return; + if(len == -1) + return; pts = 0; if (s->type == MUXER_TYPE_VIDEO) { // try to recognize frame type... |