aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/utils.c
diff options
context:
space:
mode:
authorPanagiotis Issaris <takis.issaris@uhasselt.be>2007-07-20 15:09:10 +0000
committerPanagiotis Issaris <takis.issaris@uhasselt.be>2007-07-20 15:09:10 +0000
commit7868349a9159a5e6c4cc1c1daa0a8873b6360a74 (patch)
tree399788b0986c1ee8fe2fe908b970e0b827a66862 /libavcodec/utils.c
parent90f06ceaa0dcc9a40029d6e7438fb2291e4d351c (diff)
downloadffmpeg-7868349a9159a5e6c4cc1c1daa0a8873b6360a74.tar.gz
Return AVERROR(EINVAL) when invalid width and/or height are specified to
avcodec_open. Originally committed as revision 9770 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/utils.c')
-rw-r--r--libavcodec/utils.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libavcodec/utils.c b/libavcodec/utils.c
index cd7bc1c09a..fd757fdfcb 100644
--- a/libavcodec/utils.c
+++ b/libavcodec/utils.c
@@ -847,6 +847,7 @@ int avcodec_open(AVCodecContext *avctx, AVCodec *codec)
if((avctx->coded_width||avctx->coded_height) && avcodec_check_dimensions(avctx,avctx->coded_width,avctx->coded_height)){
av_freep(&avctx->priv_data);
+ ret = AVERROR(EINVAL);
goto end;
}