From 3e77c34bd596324d1b6dc37ef4d14913ce29a61c Mon Sep 17 00:00:00 2001 From: Perfare Date: Tue, 29 Sep 2020 07:08:14 +0800 Subject: [PATCH] Fixed #618 --- AssetStudio/BundleFile.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/AssetStudio/BundleFile.cs b/AssetStudio/BundleFile.cs index 9c648f0..95d7cd9 100644 --- a/AssetStudio/BundleFile.cs +++ b/AssetStudio/BundleFile.cs @@ -200,6 +200,10 @@ namespace AssetStudio private void ReadBlocksInfoAndDirectory(EndianBinaryReader reader) { byte[] blocksInfoBytes; + if (m_Header.version >= 7) + { + reader.AlignStream(16); + } if ((m_Header.flags & 0x80) != 0) //kArchiveBlocksInfoAtTheEnd { var position = reader.Position; @@ -209,10 +213,6 @@ namespace AssetStudio } else //0x40 kArchiveBlocksAndDirectoryInfoCombined { - if (m_Header.version >= 7) - { - reader.AlignStream(16); - } blocksInfoBytes = reader.ReadBytes((int)m_Header.compressedBlocksInfoSize); } var blocksInfoCompressedStream = new MemoryStream(blocksInfoBytes);