aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/wmaenc.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2007-03-08 10:25:06 +0000
committerMichael Niedermayer <michaelni@gmx.at>2007-03-08 10:25:06 +0000
commit2ed76c08c34b7fc0acac32307cc63f3b15a58981 (patch)
tree6b9000a36dccb8147b9ec3b31fe9e19b221599c0 /libavcodec/wmaenc.c
parentc4f452fd034c0eb2f823472dd68ca786d43f2a68 (diff)
downloadffmpeg-2ed76c08c34b7fc0acac32307cc63f3b15a58981.tar.gz
bitrate sanity check (fixes assertion failure)
Originally committed as revision 8293 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/wmaenc.c')
-rw-r--r--libavcodec/wmaenc.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/wmaenc.c b/libavcodec/wmaenc.c
index f1b5529d2f..4fe3083b8c 100644
--- a/libavcodec/wmaenc.c
+++ b/libavcodec/wmaenc.c
@@ -36,6 +36,9 @@ static int encode_init(AVCodecContext * avctx){
if(avctx->channels > MAX_CHANNELS)
return -1;
+ if(avctx->bit_rate < 24*1000)
+ return -1;
+
/* extract flag infos */
flags1 = 0;
flags2 = 1;