diff --git a/app/src/main/java/com/topjohnwu/magisk/asyncs/DownloadBusybox.java b/app/src/main/java/com/topjohnwu/magisk/asyncs/DownloadBusybox.java index 513a8c998..edc3f5191 100644 --- a/app/src/main/java/com/topjohnwu/magisk/asyncs/DownloadBusybox.java +++ b/app/src/main/java/com/topjohnwu/magisk/asyncs/DownloadBusybox.java @@ -16,6 +16,7 @@ public class DownloadBusybox extends ParallelTask { private File busybox; public DownloadBusybox(Context context, File bb) { + super(context); busybox = bb; } diff --git a/app/src/main/java/com/topjohnwu/magisk/utils/Shell.java b/app/src/main/java/com/topjohnwu/magisk/utils/Shell.java index 0bd5ee542..87cbb2031 100644 --- a/app/src/main/java/com/topjohnwu/magisk/utils/Shell.java +++ b/app/src/main/java/com/topjohnwu/magisk/utils/Shell.java @@ -1,6 +1,7 @@ package com.topjohnwu.magisk.utils; import android.content.Context; +import android.text.TextUtils; import com.topjohnwu.magisk.MagiskManager; @@ -48,7 +49,7 @@ public class Shell { in.write(("id\n").getBytes("UTF-8")); in.flush(); String s = new BufferedReader(new InputStreamReader(out)).readLine(); - if (s.isEmpty() || !s.contains("uid=0")) { + if (TextUtils.isEmpty(s) || !s.contains("uid=0")) { in.close(); out.close(); process.destroy();