Root shell with no outputs

This commit is contained in:
topjohnwu
2017-07-16 03:32:29 +08:00
parent 87ea2a2bef
commit f4097a372b
9 changed files with 47 additions and 37 deletions

View File

@@ -175,11 +175,11 @@ public class SettingsActivity extends Activity {
case "hosts":
enabled = prefs.getBoolean("hosts", false);
if (enabled) {
magiskManager.rootShell.su(
magiskManager.rootShell.su_raw(
"cp -af /system/etc/hosts /magisk/.core/hosts",
"mount -o bind /magisk/.core/hosts /system/etc/hosts");
} else {
magiskManager.rootShell.su(
magiskManager.rootShell.su_raw(
"umount -l /system/etc/hosts",
"rm -f /magisk/.core/hosts");
}