Commit d1b290b9 authored by topjohnwu's avatar topjohnwu

Fix install failure

parent a6369683
......@@ -141,7 +141,9 @@ public class InstallMagisk extends ParallelTask<Void, Void, Boolean> {
HttpURLConnection conn = WebService.mustRequest(Data.magiskLink, null);
BufferedInputStream buf = new BufferedInputStream(new ProgressStream(conn));
buf.mark(Integer.MAX_VALUE);
try (OutputStream out = new FileOutputStream(new File(Download.EXTERNAL_PATH, filename))) {
File zip = new File(Download.EXTERNAL_PATH, filename);
zip.getParentFile().mkdirs();
try (OutputStream out = new FileOutputStream(zip)) {
ShellUtils.pump(buf, out);
buf.reset();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment