]> git.saurik.com Git - android/aapt.git/commitdiff
aapt: Remove terminal pointer incrementaion
authorNobuhiro Hayashi <nobuhiro.hayashi@gmail.com>
Mon, 30 Jan 2012 09:42:20 +0000 (18:42 +0900)
committerNobuhiro Hayashi <nobuhiro.hayashi@gmail.com>
Fri, 30 Mar 2012 10:23:04 +0000 (19:23 +0900)
When initialization, 'end' pointer refers terminal
character in a string. But it is incremented in
while loop. It occurs the access to non-secure memory.

Issue detail
  http://code.google.com/p/android/issues/detail?id=24896

Change-Id: I751d1154d797738c87a66374a66933528c045be5

ResourceTable.cpp

index fdb39ca08e9f555a70dc9ef4babd30952d575c05..a417311a17baaa2eb73472050aeadfa94d3a1c1f 100644 (file)
@@ -2253,7 +2253,6 @@ bool ResourceTable::getAttributeFlags(
         bool failed = false;
         while (pos < end && !failed) {
             const char16_t* start = pos;
-            end++;
             while (pos < end && *pos != '|') {
                 pos++;
             }