diff options
author | Justin Ruggles <justin.ruggles@gmail.com> | 2012-02-22 03:42:32 +0400 |
---|---|---|
committer | Justin Ruggles <justin.ruggles@gmail.com> | 2012-02-25 20:49:42 +0400 |
commit | 333506c33f21f9cf2d552fe67a8a86b5e3496a5c (patch) | |
tree | b463f33180eadd4ce49851a973eba44bf91e83de | |
parent | 6f600ab35424823fb682b5669241edcc66590a8d (diff) |
nellymoserenc: return AVERROR codes instead of -1
-rw-r--r-- | libavcodec/nellymoserenc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/nellymoserenc.c b/libavcodec/nellymoserenc.c index 104e4079e7..81e1d374a4 100644 --- a/libavcodec/nellymoserenc.c +++ b/libavcodec/nellymoserenc.c @@ -134,7 +134,7 @@ static av_cold int encode_init(AVCodecContext *avctx) if (avctx->channels != 1) { av_log(avctx, AV_LOG_ERROR, "Nellymoser supports only 1 channel\n"); - return -1; + return AVERROR(EINVAL); } if (avctx->sample_rate != 8000 && avctx->sample_rate != 16000 && @@ -142,7 +142,7 @@ static av_cold int encode_init(AVCodecContext *avctx) avctx->sample_rate != 22050 && avctx->sample_rate != 44100 && avctx->strict_std_compliance >= FF_COMPLIANCE_NORMAL) { av_log(avctx, AV_LOG_ERROR, "Nellymoser works only with 8000, 16000, 11025, 22050 and 44100 sample rate\n"); - return -1; + return AVERROR(EINVAL); } avctx->frame_size = NELLY_SAMPLES; |