mirror of
https://github.com/crskycode/GARbro.git
synced 2025-01-11 20:39:29 +08:00
(PkOpener): sanity check.
This commit is contained in:
parent
58d66c4210
commit
d05bcef548
@ -65,6 +65,8 @@ namespace GameRes.Formats.UMeSoft
|
||||
if (name_len+14 > index_end-index_offset)
|
||||
return null;
|
||||
string name = file.View.ReadString (index_offset, name_len);
|
||||
if (name.Length < (int)name_len / 2 + 1)
|
||||
return null;
|
||||
index_offset += name_len+6;
|
||||
var entry = FormatCatalog.Instance.Create<Entry> (name);
|
||||
entry.Size = file.View.ReadUInt32 (index_offset);
|
||||
|
Loading…
x
Reference in New Issue
Block a user