mirror of
https://github.com/crskycode/GARbro.git
synced 2024-11-27 15:44:00 +08:00
(ArcFile.OpenSeekableEntry): check for PackedEntry.IsPacked.
This commit is contained in:
parent
cb2ce6b96c
commit
60479757ac
@ -159,10 +159,11 @@ namespace GameRes
|
||||
using (var stream = OpenEntry (entry))
|
||||
{
|
||||
uint size;
|
||||
var packed_entry = entry as PackedEntry;
|
||||
if (stream.CanSeek)
|
||||
size = (uint)stream.Length;
|
||||
else if (entry is PackedEntry)
|
||||
size = (entry as PackedEntry).UnpackedSize;
|
||||
else if (null != packed_entry && packed_entry.IsPacked)
|
||||
size = packed_entry.UnpackedSize;
|
||||
else
|
||||
size = entry.Size;
|
||||
return new ArcView (stream, entry.Name, size);
|
||||
|
Loading…
Reference in New Issue
Block a user