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

Commit 37b93080 authored by Victoria Lease's avatar Victoria Lease Committed by Android (Google) Code Review
Browse files

Merge "malloc some advances"

parents 10caca13 3af2a37e
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -615,7 +615,7 @@ public:
                return 0;
            }
        }
        jfloat advancesArray[count];
        jfloat* advancesArray = new jfloat[count];
        jfloat totalAdvance = 0;

        TextLayout::getTextRunAdvances(paint, text, start, count, contextCount, flags,
@@ -624,6 +624,7 @@ public:
        if (advances != NULL) {
            env->SetFloatArrayRegion(advances, advancesIndex, count, advancesArray);
        }
        delete [] advancesArray;
        return totalAdvance;
    }