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

Commit 8fbbb6af authored by Lajos Molnar's avatar Lajos Molnar
Browse files

[automerger] stagefright: avoid buffer overflow in base64 decoder am:...

[automerger] stagefright: avoid buffer overflow in base64 decoder am: 5e96386a am: 5045de6f am: 8f6c537f am: 4d76a4b5 am: 5e5bb2a8 am: 61c116ad am: 9064a5c7 am: 25b927e2 am: 0ad7b10c

Change-Id: I6e8afb1115a6b989de2b07962dd3fd92cb53bd22
parents 4566e872 0ad7b10c
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -78,8 +78,7 @@ sp<ABuffer> decodeBase64(const AString &s) {
        accum = (accum << 6) | value;

        if (((i + 1) % 4) == 0) {
            out[j++] = (accum >> 16);

            if (j < outLen) { out[j++] = (accum >> 16); }
            if (j < outLen) { out[j++] = (accum >> 8) & 0xff; }
            if (j < outLen) { out[j++] = accum & 0xff; }