From 97dddd74ea5c397effe6c8200b01236745a2e564 Mon Sep 17 00:00:00 2001 From: Kurt Date: Sat, 9 May 2015 21:11:15 -0700 Subject: [PATCH] Usage bugfixes --- pk3DS/Tools/ToolsUI.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pk3DS/Tools/ToolsUI.cs b/pk3DS/Tools/ToolsUI.cs index 40a1f46..5ca2e3a 100644 --- a/pk3DS/Tools/ToolsUI.cs +++ b/pk3DS/Tools/ToolsUI.cs @@ -50,6 +50,7 @@ private void dropLeave(object sender, EventArgs e) private void openIMG(string path) { var img = png2bclim.makeBMP(path, CHK_PNG.Checked); + if (img == null) return; PB_BCLIM.Size = new Size(img.Width + 2, img.Height + 2); PB_BCLIM.BackgroundImage = img; } @@ -59,7 +60,7 @@ private void openARC(string path, bool recursing = false) { // Pre-check file length to see if it is at least valid. FileInfo fi = new FileInfo(path); - if (fi.Length > 900000) { Util.Error("File is too big!"); return; } + if (fi.Length > 50000000) { Util.Error("File is too big!"); return; } string folderPath = Path.Combine(Path.GetDirectoryName(path), Path.GetFileNameWithoutExtension(path)); // Determine if it is a DARC or a Mini