diff --git a/app/src/main/kotlin/com/simplemobiletools/filemanager/adapters/ItemsAdapter.kt b/app/src/main/kotlin/com/simplemobiletools/filemanager/adapters/ItemsAdapter.kt index 8a063322..8b642fb3 100644 --- a/app/src/main/kotlin/com/simplemobiletools/filemanager/adapters/ItemsAdapter.kt +++ b/app/src/main/kotlin/com/simplemobiletools/filemanager/adapters/ItemsAdapter.kt @@ -27,10 +27,7 @@ import com.simplemobiletools.filemanager.dialogs.CompressAsDialog import com.simplemobiletools.filemanager.extensions.config import com.simplemobiletools.filemanager.extensions.isZipFile import kotlinx.android.synthetic.main.list_item.view.* -import java.io.Closeable -import java.io.File -import java.io.FileInputStream -import java.io.FileOutputStream +import java.io.* import java.util.* import java.util.zip.ZipEntry import java.util.zip.ZipFile @@ -285,7 +282,7 @@ class ItemsAdapter(val activity: SimpleActivity, var mItems: MutableList, targetPath: String): Boolean { val queue = LinkedList() - val out = FileOutputStream(File(targetPath)) + val out = getFileOutputStream(targetPath) val zout = ZipOutputStream(out) var res: Closeable = out @@ -333,6 +330,23 @@ class ItemsAdapter(val activity: SimpleActivity, var mItems: MutableList