Merge "Fix for Cannot load etc/recovery.fstab when doing OTA upgrade" am: f4753d1cc5

Original change: https://android-review.googlesource.com/c/platform/system/core/+/2153356

Change-Id: Ic4a85f9f04acf3b12d914b2c671e40025985daea
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
David Anderson 2022-07-19 21:28:56 +00:00 committed by Automerger Merge Worker
commit f176246041

View file

@ -804,7 +804,7 @@ bool ReadDefaultFstab(Fstab* fstab) {
std::string default_fstab_path;
// Use different fstab paths for normal boot and recovery boot, respectively
if (access("/system/bin/recovery", F_OK) == 0) {
if ((access("/sbin/recovery", F_OK) == 0) || (access("/system/bin/recovery", F_OK) == 0)) {
default_fstab_path = "/etc/recovery.fstab";
} else { // normal boot
default_fstab_path = GetFstabPath();