From ee54c9441ab188eb57b8ae6038de7b8da65bef95 Mon Sep 17 00:00:00 2001 From: Maschell Date: Wed, 24 Apr 2019 13:34:21 +0200 Subject: [PATCH] Catch Exception while creating a FSTDataProviderNUSTitle --- pom.xml | 2 +- .../implementation/LocalBackupNUSTitleContainer.java | 8 +++++++- .../fuse_wiiu/implementation/LocalNUSTitleContainer.java | 7 ++++++- 3 files changed, 14 insertions(+), 3 deletions(-) diff --git a/pom.xml b/pom.xml index 7654632..40a43b1 100644 --- a/pom.xml +++ b/pom.xml @@ -92,7 +92,7 @@ com.github.Maschell JNUSLib - c47c991 + fccd8f8 org.projectlombok diff --git a/src/main/java/de/mas/wiiu/jnus/fuse_wiiu/implementation/LocalBackupNUSTitleContainer.java b/src/main/java/de/mas/wiiu/jnus/fuse_wiiu/implementation/LocalBackupNUSTitleContainer.java index 1a49ccc..24a16b0 100644 --- a/src/main/java/de/mas/wiiu/jnus/fuse_wiiu/implementation/LocalBackupNUSTitleContainer.java +++ b/src/main/java/de/mas/wiiu/jnus/fuse_wiiu/implementation/LocalBackupNUSTitleContainer.java @@ -1,6 +1,7 @@ package de.mas.wiiu.jnus.fuse_wiiu.implementation; import java.io.File; +import java.io.IOException; import java.util.Optional; import de.mas.wiiu.jnus.NUSTitle; @@ -46,7 +47,12 @@ public class LocalBackupNUSTitleContainer extends GroupFuseContainer { e1.printStackTrace(); } } - return new FSTDataProviderNUSTitle(t); + try { + return new FSTDataProviderNUSTitle(t); + } catch (IOException e) { + e.printStackTrace(); + return null; + } })); } } diff --git a/src/main/java/de/mas/wiiu/jnus/fuse_wiiu/implementation/LocalNUSTitleContainer.java b/src/main/java/de/mas/wiiu/jnus/fuse_wiiu/implementation/LocalNUSTitleContainer.java index d11c6f5..a560c93 100644 --- a/src/main/java/de/mas/wiiu/jnus/fuse_wiiu/implementation/LocalNUSTitleContainer.java +++ b/src/main/java/de/mas/wiiu/jnus/fuse_wiiu/implementation/LocalNUSTitleContainer.java @@ -58,7 +58,12 @@ public class LocalNUSTitleContainer extends GroupFuseContainer { } } - return new FSTDataProviderNUSTitle(t); + try { + return new FSTDataProviderNUSTitle(t); + } catch (IOException e) { + e.printStackTrace(); + return null; + } })); }