diff options
author | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2008-09-20 11:13:14 +0000 |
---|---|---|
committer | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2008-09-20 11:13:14 +0000 |
commit | 2c006f438042435ec67012d6b78f0374e94180bf (patch) | |
tree | 2d3f68b7996563d93974ce6372d2d1bec1de4223 /libavcodec | |
parent | a85d0c84a4ab8ced8f977c9c63d7df0cb188ac4f (diff) | |
download | ffmpeg-2c006f438042435ec67012d6b78f0374e94180bf.tar.gz |
Log an error message in case of invalid number of channels.
Originally committed as revision 15371 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/libfaac.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/libavcodec/libfaac.c b/libavcodec/libfaac.c index 2ed4f765f9..369addd6a2 100644 --- a/libavcodec/libfaac.c +++ b/libavcodec/libfaac.c @@ -38,8 +38,10 @@ static av_cold int Faac_encode_init(AVCodecContext *avctx) unsigned long samples_input, max_bytes_output; /* number of channels */ - if (avctx->channels < 1 || avctx->channels > 6) + if (avctx->channels < 1 || avctx->channels > 6) { + av_log(avctx, AV_LOG_ERROR, "encoding %d channel(s) is not allowed\n", avctx->channels); return -1; + } s->faac_handle = faacEncOpen(avctx->sample_rate, avctx->channels, |