summaryrefslogtreecommitdiffstats
path: root/recovery.cpp
diff options
context:
space:
mode:
authorTianjie Xu <xunchang@google.com>2020-07-24 21:31:13 +0200
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2020-07-24 21:31:13 +0200
commit435f3d3f16c27678fcd0ddd01efd2092208bce1a (patch)
tree8a627dfb738987b5c1a3181b96b141e628f172ae /recovery.cpp
parent[automerger skipped] Import translations. DO NOT MERGE ANYWHERE am: fd33b4992d -s ours (diff)
parentMerge changes I0f3f0333,If447b2cf am: 435a5fc0c2 (diff)
downloadandroid_bootable_recovery-435f3d3f16c27678fcd0ddd01efd2092208bce1a.tar
android_bootable_recovery-435f3d3f16c27678fcd0ddd01efd2092208bce1a.tar.gz
android_bootable_recovery-435f3d3f16c27678fcd0ddd01efd2092208bce1a.tar.bz2
android_bootable_recovery-435f3d3f16c27678fcd0ddd01efd2092208bce1a.tar.lz
android_bootable_recovery-435f3d3f16c27678fcd0ddd01efd2092208bce1a.tar.xz
android_bootable_recovery-435f3d3f16c27678fcd0ddd01efd2092208bce1a.tar.zst
android_bootable_recovery-435f3d3f16c27678fcd0ddd01efd2092208bce1a.zip
Diffstat (limited to 'recovery.cpp')
-rw-r--r--recovery.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/recovery.cpp b/recovery.cpp
index df13835be..84deeb45f 100644
--- a/recovery.cpp
+++ b/recovery.cpp
@@ -559,15 +559,15 @@ static void set_retry_bootloader_message(int retry_count, const std::vector<std:
}
}
-static bool bootreason_in_blacklist() {
+static bool bootreason_in_blocklist() {
std::string bootreason = android::base::GetProperty("ro.boot.bootreason", "");
if (!bootreason.empty()) {
// More bootreasons can be found in "system/core/bootstat/bootstat.cpp".
- static const std::vector<std::string> kBootreasonBlacklist{
+ static const std::vector<std::string> kBootreasonBlocklist{
"kernel_panic",
"Panic",
};
- for (const auto& str : kBootreasonBlacklist) {
+ for (const auto& str : kBootreasonBlocklist) {
if (android::base::EqualsIgnoreCase(str, bootreason)) return true;
}
}
@@ -734,10 +734,10 @@ Device::BuiltinAction start_recovery(Device* device, const std::vector<std::stri
// Log the error code to last_install when installation skips due to low battery.
log_failure_code(kLowBattery, update_package);
status = INSTALL_SKIPPED;
- } else if (retry_count == 0 && bootreason_in_blacklist()) {
+ } else if (retry_count == 0 && bootreason_in_blocklist()) {
// Skip update-on-reboot when bootreason is kernel_panic or similar
- ui->Print("bootreason is in the blacklist; skip OTA installation\n");
- log_failure_code(kBootreasonInBlacklist, update_package);
+ ui->Print("bootreason is in the blocklist; skip OTA installation\n");
+ log_failure_code(kBootreasonInBlocklist, update_package);
status = INSTALL_SKIPPED;
} else {
// It's a fresh update. Initialize the retry_count in the BCB to 1; therefore we can later