diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2011-12-18 23:54:56 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2012-01-03 19:49:55 +0100 |
commit | 0815a2907a55f20e18679c4d35c8421ec7317718 (patch) | |
tree | d40bfd4ea9fd92d663b41cbc985d3b8c1efd2e0c | |
parent | d1e1674f66f584bd839bf6cd512af03329e557bf (diff) | |
download | ffmpeg-0815a2907a55f20e18679c4d35c8421ec7317718.tar.gz |
rl2demux: Fix FPE
Fixes Ticket788
Bug found by Oana Stratulat
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit f371396dfb95c116a05e9b9f690fa916bb2d815e)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | libavformat/rl2.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libavformat/rl2.c b/libavformat/rl2.c index 530e0dfb9a..78edec5b18 100644 --- a/libavformat/rl2.c +++ b/libavformat/rl2.c @@ -138,6 +138,9 @@ static av_cold int rl2_read_header(AVFormatContext *s, /** setup audio stream if present */ if(sound_rate){ + if(channels <= 0) + return AVERROR_INVALIDDATA; + pts_num = def_sound_size; pts_den = rate; |