Fixed: correctly calculate symbol-name lengths.
Even though the grammar promises us the symbol names will never occupy more than one byte per character, it's good practice to add this anyway (since we already do it for the data table).
This commit is contained in:
parent
7672bea631
commit
ac51f19b85
1 changed files with 1 additions and 1 deletions
|
@ -37,7 +37,7 @@ namespace arookas
|
|||
writer.WriteS32(0);
|
||||
writer.WriteS32(0);
|
||||
|
||||
ofs += sym.Name.Length + 1; // include null terminator
|
||||
ofs += writer.Encoding.GetByteCount(sym.Name) + 1; // include null terminator
|
||||
}
|
||||
foreach (var sym in this)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue