From e6d901f9b9c979ab39f55007e91f5fb84136ec99 Mon Sep 17 00:00:00 2001 From: Matt Nadareski Date: Wed, 14 Sep 2016 10:06:31 -0700 Subject: [PATCH] [FIleTools] Fix SuperDAT write out --- SabreTools.Helper/Tools/FileTools.cs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/SabreTools.Helper/Tools/FileTools.cs b/SabreTools.Helper/Tools/FileTools.cs index 2ed52e23..b0ad2207 100644 --- a/SabreTools.Helper/Tools/FileTools.cs +++ b/SabreTools.Helper/Tools/FileTools.cs @@ -39,6 +39,12 @@ namespace SabreTools.Helper ZipArchive outarchive = null; try { + // If the full output path doesn't exist, create it + if (!Directory.Exists(Path.GetDirectoryName(archiveFileName))) + { + Directory.CreateDirectory(Path.GetDirectoryName(archiveFileName)); + } + // If the archive doesn't exist, create it if (!File.Exists(archiveFileName)) { @@ -650,7 +656,7 @@ namespace SabreTools.Helper MD5 = string.Empty, SHA1 = string.Empty, }, - Date = temp.LastWriteTime.ToString(), + //Date = temp.LastWriteTime.ToString(), }; try