summaryrefslogtreecommitdiff
path: root/tools/aapt/Resource.cpp
diff options
context:
space:
mode:
author Ryan Mitchell <rtmitchell@google.com> 2020-11-13 00:05:40 +0000
committer Android (Google) Code Review <android-gerrit@google.com> 2020-11-13 00:05:40 +0000
commitc234812e275368f47d798112e1de49a8aad99753 (patch)
tree2c029a88ba773fa77936dc89ccd4f6328e2ece07 /tools/aapt/Resource.cpp
parent8f8eaec80190bc4a35851b9efbef412dd63efb70 (diff)
parent5602dc9374934a42964e0f57faa3c0aad43003e1 (diff)
Merge changes from topic "libaw-hardening"
* changes: Do not cache bag parent stack until requested Cache resolved theme values libandroidfw hardening for IncFs
Diffstat (limited to 'tools/aapt/Resource.cpp')
-rw-r--r--tools/aapt/Resource.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/aapt/Resource.cpp b/tools/aapt/Resource.cpp
index ab6dced5b67d..dd3ebdbdea09 100644
--- a/tools/aapt/Resource.cpp
+++ b/tools/aapt/Resource.cpp
@@ -519,7 +519,7 @@ static int validateAttr(const String8& path, const ResTable& table,
String8(parser.getElementName(&len)).string(), attr);
return ATTR_NOT_FOUND;
}
- if ((str=pool->stringAt(value.data, &len)) == NULL) {
+ if ((str = UnpackOptionalString(pool->stringAt(value.data), &len)) == NULL) {
fprintf(stderr, "%s:%d: Tag <%s> attribute %s has corrupt string value.\n",
path.string(), parser.getLineNumber(),
String8(parser.getElementName(&len)).string(), attr);