From c25214aaf45bba0a8575699a6bb5ba7cc157101a Mon Sep 17 00:00:00 2001 From: cpw Date: Sun, 10 Feb 2019 15:58:12 -0500 Subject: [PATCH] Fix #5429 properly, without breaking symlinks on linux.. Signed-off-by: cpw --- .../java/net/minecraftforge/fml/loading/FileUtils.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/fmllauncher/java/net/minecraftforge/fml/loading/FileUtils.java b/src/fmllauncher/java/net/minecraftforge/fml/loading/FileUtils.java index 94027f0a41..31e6f345e2 100644 --- a/src/fmllauncher/java/net/minecraftforge/fml/loading/FileUtils.java +++ b/src/fmllauncher/java/net/minecraftforge/fml/loading/FileUtils.java @@ -34,6 +34,9 @@ public class FileUtils private static final Logger LOGGER = LogManager.getLogger(); public static Path getOrCreateDirectory(Path dirPath, String dirLabel) { + if (!Files.isDirectory(dirPath.getParent())) { + getOrCreateDirectory(dirPath.getParent(), "parent of "+dirLabel); + } if (!Files.isDirectory(dirPath)) { LOGGER.debug(CORE,"Making {} directory : {}", dirLabel, dirPath);