Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2a443457 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "m4v_h263: Add check on the encode dimension"

parents f224b6d5 4e70ae10
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -491,6 +491,9 @@ OSCL_EXPORT_REF Bool PVInitVideoEncoder(VideoEncControls *encoderControl, Vid
    }
    for (i = 0; i < encParams->nLayers; i++)
    {
        if (encOption->encHeight[i] == 0 || encOption->encWidth[i] == 0 ||
                encOption->encHeight[i] % 16 != 0 || encOption->encWidth[i] % 16 != 0)
            goto CLEAN_UP;
        encParams->LayerHeight[i] = encOption->encHeight[i];
        encParams->LayerWidth[i] = encOption->encWidth[i];
    }