g2m: Relax resolution change constraints
authorVittorio Giovara <vittorio.giovara at gmail.com>
Wed, 7 Oct 2015 13:16:44 +0000 (15:16 +0200)
committerLuca Barbato <lu_zero@gentoo.org>
Wed, 7 Oct 2015 16:45:49 +0000 (18:45 +0200)
Do not fail when original resolution is smaller than current one,
as the frame buffer is resized automatically.

Signed-off-by: Vittorio Giovara <vittorio.giovara at gmail.com>
libavcodec/g2meet.c

index 85f53e2..a89610d 100644 (file)
@@ -1410,8 +1410,7 @@ static int g2m_decode_frame(AVCodecContext *avctx, void *data,
             }
             c->width  = bytestream2_get_be32(&bc);
             c->height = bytestream2_get_be32(&bc);
-            if (c->width  < 16 || c->width  > c->orig_width ||
-                c->height < 16 || c->height > c->orig_height) {
+            if (c->width < 16 || c->height < 16) {
                 av_log(avctx, AV_LOG_ERROR,
                        "Invalid frame dimensions %dx%d\n",
                        c->width, c->height);