From d0160dff22c57b9feec405c65fe9821975a71404 Mon Sep 17 00:00:00 2001 From: Adam Barth Date: Mon, 19 Feb 2018 08:38:45 -0800 Subject: [PATCH] Reduce logspam in DirectoryAssetBundle (#4690) It's not an error to request an asset that doesn't exist. In fact, we request kernel_blob.bin unconditionally at startup, which doesn't typically exist. --- assets/directory_asset_bundle.cc | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/assets/directory_asset_bundle.cc b/assets/directory_asset_bundle.cc index 2254b43e012cb..43933079a81bd 100644 --- a/assets/directory_asset_bundle.cc +++ b/assets/directory_asset_bundle.cc @@ -25,10 +25,8 @@ bool DirectoryAssetBundle::GetAsBuffer(const std::string& asset_name, return false; #else fxl::UniqueFD asset_file(openat(fd_.get(), asset_name.c_str(), O_RDONLY)); - if (!asset_file.is_valid()) { - FXL_LOG(ERROR) << "Could not load asset " << asset_name; + if (!asset_file.is_valid()) return false; - } constexpr size_t kBufferSize = 1 << 16; size_t offset = 0;