summaryrefslogtreecommitdiff
path: root/libs/androidfw/AttributeResolution.cpp
diff options
context:
space:
mode:
author Ryan Mitchell <rtmitchell@google.com> 2020-11-13 23:55:20 +0000
committer Ryan Mitchell <rtmitchell@google.com> 2020-11-13 23:55:20 +0000
commit6ca48473e533a8b89abac6294a0bb8130b8c8c89 (patch)
treeda96bc5ed4429763b2aec93021ec7d0340ce0b98 /libs/androidfw/AttributeResolution.cpp
parent06a7331b84ceb4b39d39e4af187d1f988475893a (diff)
Revert "Cache resolved theme values"
Revert "Move map_ptr to incfs namspace" Revert submission 12787270 Reason for revert: b/173250495 Reverted Changes: I5cd1bc8a2:libandroidfw hardening for IncFs Ice5dbcfb2:Move map_ptr to incfs namspace I29ccdc8ed:Do not cache bag parent stack until requested I1e9e9acaa:Cache resolved theme values Change-Id: Ibec051c79dfd28783a57b9ae82ebd8cdbed82fce
Diffstat (limited to 'libs/androidfw/AttributeResolution.cpp')
-rw-r--r--libs/androidfw/AttributeResolution.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/libs/androidfw/AttributeResolution.cpp b/libs/androidfw/AttributeResolution.cpp
index 347b4ec8346c..71919fdbb736 100644
--- a/libs/androidfw/AttributeResolution.cpp
+++ b/libs/androidfw/AttributeResolution.cpp
@@ -39,7 +39,8 @@ class XmlAttributeFinder
: public BackTrackingAttributeFinder<XmlAttributeFinder, size_t> {
public:
explicit XmlAttributeFinder(const ResXMLParser* parser)
- : BackTrackingAttributeFinder(0, parser != nullptr ? parser->getAttributeCount() : 0),
+ : BackTrackingAttributeFinder(
+ 0, parser != nullptr ? parser->getAttributeCount() : 0),
parser_(parser) {}
inline uint32_t GetAttribute(size_t index) const {
@@ -177,7 +178,7 @@ base::expected<std::monostate, IOError> ResolveAttrs(Theme* theme, uint32_t def_
value = *attr_value;
DEBUG_LOG("-> From theme: type=0x%x, data=0x%08x", value.type, value.data);
- const auto result = assetmanager->ResolveReference(value, true /* cache_value */);
+ const auto result = assetmanager->ResolveReference(value);
if (UNLIKELY(IsIOError(result))) {
return base::unexpected(GetIOError(result.error()));
}
@@ -309,7 +310,7 @@ base::expected<std::monostate, IOError> ApplyStyle(Theme* theme, ResXMLParser* x
value = *attr_value;
DEBUG_LOG("-> From theme: type=0x%x, data=0x%08x", value.type, value.data);
- auto result = assetmanager->ResolveReference(value, true /* cache_value */);
+ auto result = assetmanager->ResolveReference(value);
if (UNLIKELY(IsIOError(result))) {
return base::unexpected(GetIOError(result.error()));
}