From 6d31a2f656d5fb09763cfde908edeb7e3e1e643c Mon Sep 17 00:00:00 2001 From: Anthony Calosa Date: Sat, 1 May 2021 14:27:02 +0000 Subject: [PATCH] Update GuiDownloadZipService.java --- .../java/forge/gui/download/GuiDownloadZipService.java | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/forge-gui/src/main/java/forge/gui/download/GuiDownloadZipService.java b/forge-gui/src/main/java/forge/gui/download/GuiDownloadZipService.java index 2f94c8966ee..576ca23345c 100644 --- a/forge-gui/src/main/java/forge/gui/download/GuiDownloadZipService.java +++ b/forge-gui/src/main/java/forge/gui/download/GuiDownloadZipService.java @@ -172,7 +172,13 @@ public class GuiDownloadZipService extends GuiDownloadService { } } - final ZipFile zipFile = new ZipFile(zipFilename, Charset.forName("IBM437")); + final Charset charset = Charset.forName("IBM437"); + ZipFile zipFile; + try { + zipFile = new ZipFile(zipFilename, charset); + } catch (Throwable e) { //some older Android versions need the old method + zipFile = new ZipFile(zipFilename); + } final Enumeration entries = zipFile.entries(); progressBar.reset();