From 6a4788e7b31ae2382466048289dbba21b2dff3bb Mon Sep 17 00:00:00 2001
From: Michael Niedermayer <michael@niedermayer.cc>
Date: Sun, 5 Aug 2018 17:10:22 +0200
Subject: [PATCH] avcodec/gdv: Replace loop in gdv_decode_frame() by memcpy()

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
---
 libavcodec/gdv.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/libavcodec/gdv.c b/libavcodec/gdv.c
index aea15a88ef0..1623febd1a9 100644
--- a/libavcodec/gdv.c
+++ b/libavcodec/gdv.c
@@ -479,9 +479,7 @@ static int gdv_decode_frame(AVCodecContext *avctx, void *data,
 
         for (y = 0; y < avctx->height; y++) {
             if (!gdv->scale_v) {
-                for (x = 0; x < avctx->width; x++) {
-                    dst[didx + x] = gdv->frame[sidx + x];
-                }
+                memcpy(dst + didx, gdv->frame + sidx, avctx->width);
             } else {
                 for (x = 0; x < avctx->width; x++) {
                     dst[didx + x] = gdv->frame[sidx + x/2];
-- 
GitLab