From 3c22e9c077b7a54bb7ae53d04797716609edd9a3 Mon Sep 17 00:00:00 2001 From: morkt Date: Sat, 21 Nov 2015 10:15:54 +0400 Subject: [PATCH] (FileSystemStack.Flush): don't dispose of LastVisitedArc if it currently resides on top of the stack. --- GameRes/FileSystem.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/GameRes/FileSystem.cs b/GameRes/FileSystem.cs index a0789d99..3015c5bb 100644 --- a/GameRes/FileSystem.cs +++ b/GameRes/FileSystem.cs @@ -517,7 +517,7 @@ namespace GameRes public void Flush () { - if (LastVisitedArc != null) + if (LastVisitedArc != null && (0 == Count || LastVisitedArc != Top)) { LastVisitedArc.Dispose(); LastVisitedArc = null;