aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec
diff options
context:
space:
mode:
authorStefano Sabatini <stefano.sabatini-lala@poste.it>2010-04-25 15:05:16 +0000
committerStefano Sabatini <stefano.sabatini-lala@poste.it>2010-04-25 15:05:16 +0000
commit4cf1ba0445a2b288f0ca47e36d780dec4d7d4e87 (patch)
treef29863a685d005db345dedc1ea5cd663d6e4f3a3 /libavcodec
parent2ef6c1242aeebf863b86f34229490a023bfe65dc (diff)
downloadffmpeg-4cf1ba0445a2b288f0ca47e36d780dec4d7d4e87.tar.gz
Make avcodec_check_dimensions() return AVERROR(EINVAL) rather than -1
in case of invalid picture size. Originally committed as revision 22962 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/utils.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/utils.c b/libavcodec/utils.c
index 34e8ae45fe..87facec8f4 100644
--- a/libavcodec/utils.c
+++ b/libavcodec/utils.c
@@ -224,7 +224,7 @@ int avcodec_check_dimensions(void *av_log_ctx, unsigned int w, unsigned int h){
return 0;
av_log(av_log_ctx, AV_LOG_ERROR, "picture size invalid (%ux%u)\n", w, h);
- return -1;
+ return AVERROR(EINVAL);
}
int avcodec_default_get_buffer(AVCodecContext *s, AVFrame *pic){