Codechange: Use std::array instead of C array for automatic deep-copies.

This commit is contained in:
Peter Nelson
2023-05-18 19:56:09 +01:00
committed by PeterN
parent acec34a0fe
commit c23aae96a2
4 changed files with 5 additions and 25 deletions

View File

@@ -7191,7 +7191,7 @@ static void GRFLoadError(ByteReader *buf)
}
/* Only two parameter numbers can be used in the string. */
for (uint i = 0; i < lengthof(error->param_value) && buf->HasData(); i++) {
for (uint i = 0; i < error->param_value.size() && buf->HasData(); i++) {
uint param_number = buf->ReadByte();
error->param_value[i] = _cur.grffile->GetParam(param_number);
}