diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/com/dabomstew/pkrandom/Utils.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/com/dabomstew/pkrandom/Utils.java b/src/com/dabomstew/pkrandom/Utils.java index 8417567..2fd8b71 100644 --- a/src/com/dabomstew/pkrandom/Utils.java +++ b/src/com/dabomstew/pkrandom/Utils.java @@ -117,7 +117,9 @@ public class Utils { public static File getExecutionLocation() throws UnsupportedEncodingException { URL location = NewRandomizerGUI.class.getProtectionDomain().getCodeSource().getLocation(); - return new File(java.net.URLDecoder.decode(location.getFile(), "UTF-8")); + String file = location.getFile(); + String plusEncoded = file.replaceAll("\\+", "%2b"); + return new File(java.net.URLDecoder.decode(plusEncoded, "UTF-8")); } public static class InvalidROMException extends Exception { |