X-Git-Url: https://git.saurik.com/android/aapt.git/blobdiff_plain/0a9550cf47a3f0d31d186c34cfda05ff709b6b41..8d0084d3b2878ffe092396cabf778c2114675dd2:/ResourceTable.cpp diff --git a/ResourceTable.cpp b/ResourceTable.cpp index 0c0b2ea..0195727 100644 --- a/ResourceTable.cpp +++ b/ResourceTable.cpp @@ -2304,10 +2304,8 @@ bool ResourceTable::getAttributeFlags( const char16_t* end = name + nameLen; const char16_t* pos = name; - bool failed = false; - while (pos < end && !failed) { + while (pos < end) { const char16_t* start = pos; - end++; while (pos < end && *pos != '|') { pos++; } @@ -2333,9 +2331,7 @@ bool ResourceTable::getAttributeFlags( // Didn't find this flag identifier. return false; } - if (pos < end) { - pos++; - } + pos++; } return true; @@ -2602,7 +2598,7 @@ status_t ResourceTable::flatten(Bundle* bundle, const sp& dest) // Iterate through all data, collecting all values (strings, // references, etc). - StringPool valueStrings = StringPool(false, useUTF8); + StringPool valueStrings(useUTF8); Vector > allEntries; for (pi=0; pi p = mOrderedPackages.itemAt(pi); @@ -2611,8 +2607,8 @@ status_t ResourceTable::flatten(Bundle* bundle, const sp& dest) continue; } - StringPool typeStrings = StringPool(false, useUTF8); - StringPool keyStrings = StringPool(false, useUTF8); + StringPool typeStrings(useUTF8); + StringPool keyStrings(useUTF8); const size_t N = p->getOrderedTypes().size(); for (size_t ti=0; ti