Commit c87fdbea authored by topjohnwu's avatar topjohnwu

Fix erroneous stream close

parent ec8fffe6
......@@ -189,7 +189,7 @@ abstract class MagiskInstallImpl protected constructor(
console.add("-- Extracting: $name")
val extract = File(installDir, name)
decompressedStream().writeTo(extract)
extract.outputStream().use { decompressedStream().copyTo(it) }
} else if (entry.name.contains("vbmeta.img")) {
val rawData = decompressedStream().readBytes()
// Valid vbmeta.img should be at least 256 bytes
......
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