From fe2a4ca37913331b8d740cd0a43462df6d16944d Mon Sep 17 00:00:00 2001 From: Fabrice Bellard Date: Sun, 2 Feb 2003 19:51:40 +0000 Subject: [PATCH] fixed copy Originally committed as revision 1535 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavformat/jpeg.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libavformat/jpeg.c b/libavformat/jpeg.c index 38a955b31d..0aec8f34a2 100644 --- a/libavformat/jpeg.c +++ b/libavformat/jpeg.c @@ -125,11 +125,11 @@ static int jpeg_read(ByteIOContext *f, switch(c->pix_fmt) { default: case PIX_FMT_YUV420P: - w >>= 1; - h >>= 1; + w = (w + 1) >> 1; + h = (h + 1) >> 1; break; case PIX_FMT_YUV422P: - w >>= 1; + w = (w + 1) >> 1; break; case PIX_FMT_YUV444P: break;