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

Commit 442c8226 authored by Yunlian Jiang's avatar Yunlian Jiang Committed by android-build-merger
Browse files

Merge "Fix warning: Potential leak of memory pointed to by 'set'" am: 58ba53bd am: 0889a8a0

am: 2b53748a

Change-Id: Icec70d3e3efef0eea9c117911821dfd05bcb2ced
parents 86e44979 2b53748a
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -4430,6 +4430,7 @@ ssize_t ResTable::getBagLocked(uint32_t resID, const bag_entry** outBag,
        if (curOff > (dtohl(entry.type->header.size)-sizeof(ResTable_map))) {
            ALOGW("ResTable_map at %d is beyond type chunk data %d",
                 (int)curOff, dtohl(entry.type->header.size));
            free(set);
            return BAD_TYPE;
        }
        map = (const ResTable_map*)(((const uint8_t*)entry.type) + curOff);
@@ -4442,6 +4443,7 @@ ssize_t ResTable::getBagLocked(uint32_t resID, const bag_entry** outBag,
            if (grp->dynamicRefTable.lookupResourceId(&newName) != NO_ERROR) {
                ALOGE("Failed resolving ResTable_map name at %d with ident 0x%08x",
                        (int) curOff, (int) newName);
                free(set);
                return UNKNOWN_ERROR;
            }
        }