mirror of
https://github.com/crskycode/GARbro.git
synced 2024-11-27 07:34:00 +08:00
(PackOpener): additional sanity check.
This commit is contained in:
parent
fb88fa58dc
commit
d35f790994
@ -52,7 +52,7 @@ namespace GameRes.Formats.BlackRainbow
|
|||||||
using (var input = file.CreateStream (0, index_length))
|
using (var input = file.CreateStream (0, index_length))
|
||||||
{
|
{
|
||||||
var reader = new IndexReader (input, file.MaxOffset);
|
var reader = new IndexReader (input, file.MaxOffset);
|
||||||
if (!reader.ReadDir ("", 8, index_length))
|
if (!reader.ReadDir ("", 8, index_length) || 0 == reader.Dir.Count)
|
||||||
return null;
|
return null;
|
||||||
return new ArcFile (file, this, reader.Dir);
|
return new ArcFile (file, this, reader.Dir);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user