From c3e79405f7f30471646fb46fad8f286ed8e6a433 Mon Sep 17 00:00:00 2001 From: Matthew Date: Tue, 19 Oct 2010 17:57:20 +1300 Subject: [PATCH] Make sure mod package dir exists before extraction. --- OpenRA.Utility/Program.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/OpenRA.Utility/Program.cs b/OpenRA.Utility/Program.cs index e05ca6b3ac..6eb70c3c73 100644 --- a/OpenRA.Utility/Program.cs +++ b/OpenRA.Utility/Program.cs @@ -168,6 +168,9 @@ namespace OpenRA.Utility string filepath = string.Format("{0}{1}{2}-packages.zip", dest, Path.DirectorySeparatorChar, mod); string modPackageDir = string.Format("mods{0}{1}{0}packages{0}", Path.DirectorySeparatorChar, mod); + if (!Directory.Exists(modPackageDir)) + Directory.CreateDirectory(modPackageDir); + using (var z = new ZipInputStream(File.OpenRead(filepath))) { ZipEntry entry;