diff options
-rw-r--r-- | src/mg_schematic.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mg_schematic.cpp b/src/mg_schematic.cpp index d203a7105..bb60cf5fd 100644 --- a/src/mg_schematic.cpp +++ b/src/mg_schematic.cpp @@ -57,7 +57,8 @@ void Schematic::updateContentIds() flags |= SCHEM_CIDS_UPDATED; - for (size_t i = 0; i != size.X * size.Y * size.Z; i++) + size_t bufsize = size.X * size.Y * size.Z; + for (size_t i = 0; i != bufsize; i++) schemdata[i].setContent(c_nodes[schemdata[i].getContent()]); } |