summaryrefslogtreecommitdiffstats
path: root/recovery.cpp
diff options
context:
space:
mode:
authorMark Salyzyn <salyzyn@google.com>2018-08-29 19:44:33 +0200
committerMark Salyzyn <salyzyn@google.com>2018-10-11 18:04:56 +0200
commitfdea242a91217bc5d476b9ffa8eb3a5e71e71eef (patch)
treeea0e7c2c968d5399b252c6e08e4c00923ac2cce5 /recovery.cpp
parentMerge "Use only signed/unsigned numbers with ParseInt/ParseUint respectively" (diff)
downloadandroid_bootable_recovery-fdea242a91217bc5d476b9ffa8eb3a5e71e71eef.tar
android_bootable_recovery-fdea242a91217bc5d476b9ffa8eb3a5e71e71eef.tar.gz
android_bootable_recovery-fdea242a91217bc5d476b9ffa8eb3a5e71e71eef.tar.bz2
android_bootable_recovery-fdea242a91217bc5d476b9ffa8eb3a5e71e71eef.tar.lz
android_bootable_recovery-fdea242a91217bc5d476b9ffa8eb3a5e71e71eef.tar.xz
android_bootable_recovery-fdea242a91217bc5d476b9ffa8eb3a5e71e71eef.tar.zst
android_bootable_recovery-fdea242a91217bc5d476b9ffa8eb3a5e71e71eef.zip
Diffstat (limited to 'recovery.cpp')
-rw-r--r--recovery.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/recovery.cpp b/recovery.cpp
index 7cc344bce..3ea282fc0 100644
--- a/recovery.cpp
+++ b/recovery.cpp
@@ -78,6 +78,7 @@ static constexpr const char* CACHE_ROOT = "/cache";
static constexpr const char* DATA_ROOT = "/data";
static constexpr const char* METADATA_ROOT = "/metadata";
static constexpr const char* SDCARD_ROOT = "/sdcard";
+static constexpr const char* SYSTEM_ROOT = "/system";
// We define RECOVERY_API_VERSION in Android.mk, which will be picked up by build system and packed
// into target_files.zip. Assert the version defined in code and in Android.mk are consistent.
@@ -852,12 +853,12 @@ static Device::BuiltinAction prompt_and_wait(Device* device, int status) {
}
case Device::MOUNT_SYSTEM:
// the system partition is mounted at /mnt/system
- if (android::base::GetBoolProperty("ro.build.system_root_image", false)) {
+ if (volume_for_mount_point(SYSTEM_ROOT) == nullptr) {
if (ensure_path_mounted_at("/", "/mnt/system") != -1) {
ui->Print("Mounted /system.\n");
}
} else {
- if (ensure_path_mounted_at("/system", "/mnt/system") != -1) {
+ if (ensure_path_mounted_at(SYSTEM_ROOT, "/mnt/system") != -1) {
ui->Print("Mounted /system.\n");
}
}