summaryrefslogtreecommitdiff
path: root/libs/androidfw/AssetManager2.cpp
diff options
context:
space:
mode:
author Yurii Zubrytskyi <zyy@google.com> 2022-11-30 23:53:59 -0800
committer Yurii Zubrytskyi <zyy@google.com> 2022-12-01 10:01:57 -0800
commita5bc9585b2bd09868fb6e0339dd5b8e288303b7e (patch)
tree5a715a344f9944e497708c80258c37228198ca11 /libs/androidfw/AssetManager2.cpp
parent3d0a6c17f458e77063c6cf49e0bde2da202abd8d (diff)
[res] Refactor AssetManager + Providers
- More moves where possible - Better interface for PathOrDebugName creation - function_ref as a callback - Get rid of some obsolete Util.h code - Shut up the logging in host mode, and ignore all calls Bug: 237583012 Test: build + boot + UTs Change-Id: Ia71fc1c83f17ab5ce3cac1179f74534f7ad2a3cb
Diffstat (limited to 'libs/androidfw/AssetManager2.cpp')
-rw-r--r--libs/androidfw/AssetManager2.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/libs/androidfw/AssetManager2.cpp b/libs/androidfw/AssetManager2.cpp
index cc7e8714c0ac..68f5e4a88c7e 100644
--- a/libs/androidfw/AssetManager2.cpp
+++ b/libs/androidfw/AssetManager2.cpp
@@ -1562,11 +1562,11 @@ base::expected<std::monostate, IOError> Theme::SetTo(const Theme& source) {
std::unordered_map<ApkAssetsCookie, SourceToDestinationRuntimePackageMap> src_asset_cookie_id_map;
// Determine which ApkAssets are loaded in both theme AssetManagers.
- const auto src_assets = source.asset_manager_->GetApkAssets();
+ const auto& src_assets = source.asset_manager_->GetApkAssets();
for (size_t i = 0; i < src_assets.size(); i++) {
const ApkAssets* src_asset = src_assets[i];
- const auto dest_assets = asset_manager_->GetApkAssets();
+ const auto& dest_assets = asset_manager_->GetApkAssets();
for (size_t j = 0; j < dest_assets.size(); j++) {
const ApkAssets* dest_asset = dest_assets[j];
if (src_asset != dest_asset) {