mirror of
https://github.com/OpenMW/openmw.git
synced 2025-12-01 14:34:33 +00:00
Use at instead of operator[] to access nif record types
To fix crash on out of bounds access.
This commit is contained in:
parent
20c388a410
commit
0c2164330b
1 changed files with 1 additions and 1 deletions
|
|
@ -674,7 +674,7 @@ namespace Nif
|
||||||
{
|
{
|
||||||
std::unique_ptr<Record> r;
|
std::unique_ptr<Record> r;
|
||||||
|
|
||||||
std::string rec = hasRecTypeListings ? recTypes[recTypeIndices[i]] : nif.get<std::string>();
|
std::string rec = hasRecTypeListings ? recTypes.at(recTypeIndices[i]) : nif.get<std::string>();
|
||||||
if (rec.empty())
|
if (rec.empty())
|
||||||
{
|
{
|
||||||
std::stringstream error;
|
std::stringstream error;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue