summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatt Mower <mowerm@gmail.com>2015-11-18 17:31:33 +0100
committerDees Troy <dees_troy@teamw.in>2015-12-02 05:10:40 +0100
commit954601904a5da6a1d7d606b2f067d2b3d574c741 (patch)
tree7ed33c813c389245113d9d54423dbd1eb8d07932
parentlibblkid: remove various no-op variable checks (diff)
downloadandroid_bootable_recovery-954601904a5da6a1d7d606b2f067d2b3d574c741.tar
android_bootable_recovery-954601904a5da6a1d7d606b2f067d2b3d574c741.tar.gz
android_bootable_recovery-954601904a5da6a1d7d606b2f067d2b3d574c741.tar.bz2
android_bootable_recovery-954601904a5da6a1d7d606b2f067d2b3d574c741.tar.lz
android_bootable_recovery-954601904a5da6a1d7d606b2f067d2b3d574c741.tar.xz
android_bootable_recovery-954601904a5da6a1d7d606b2f067d2b3d574c741.tar.zst
android_bootable_recovery-954601904a5da6a1d7d606b2f067d2b3d574c741.zip
-rw-r--r--twrp.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/twrp.cpp b/twrp.cpp
index ff7d55fcb..d49ae801c 100644
--- a/twrp.cpp
+++ b/twrp.cpp
@@ -375,7 +375,7 @@ int main(int argc, char **argv) {
// Disable flashing of stock recovery
TWFunc::Disable_Stock_Recovery_Replace();
// Check for su to see if the device is rooted or not
- if (PartitionManager.Mount_By_Path("/system", false) && DataManager::GetIntValue("tw_mount_system_ro") == 0) {
+ if (DataManager::GetIntValue("tw_mount_system_ro") == 0 && PartitionManager.Mount_By_Path("/system", false)) {
if (TWFunc::Path_Exists("/supersu/su") && TWFunc::Path_Exists("/system/bin") && !TWFunc::Path_Exists("/system/bin/su") && !TWFunc::Path_Exists("/system/xbin/su") && !TWFunc::Path_Exists("/system/bin/.ext/.su")) {
// Device doesn't have su installed
DataManager::SetValue("tw_busy", 1);