From f7037896858eca46a6584048bcd5300ed76cec6d Mon Sep 17 00:00:00 2001 From: morkt Date: Thu, 5 Mar 2015 17:40:13 +0400 Subject: [PATCH] (PrefixStream.Read): changed underlying stream position reset logic. --- ArcFormats/ArcCommon.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ArcFormats/ArcCommon.cs b/ArcFormats/ArcCommon.cs index 1be580a3..336e2d4c 100644 --- a/ArcFormats/ArcCommon.cs +++ b/ArcFormats/ArcCommon.cs @@ -86,11 +86,11 @@ namespace GameRes.Formats read += header_count; offset += header_count; count -= header_count; - if (count > 0) - m_stream.Position = 0; } if (count > 0) { + if (m_header.Length == m_position) + m_stream.Position = 0; int stream_read = m_stream.Read (buffer, offset, count); m_position += stream_read; read += stream_read;