Skip to content

Commit

Permalink
Merge pull request #36407 from timothyqiu/maybe-copy-paste-error
Browse files Browse the repository at this point in the history
Fixes crash when saving scene
  • Loading branch information
akien-mga authored Sep 13, 2020
2 parents d2b1326 + 38147da commit de465c4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions servers/rendering/rasterizer_rd/rasterizer_storage_rd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3208,9 +3208,9 @@ Vector<float> RasterizerStorageRD::multimesh_get_buffer(RID p_multimesh) const {

Vector<uint8_t> buffer = RD::get_singleton()->buffer_get_data(multimesh->buffer);
Vector<float> ret;
ret.resize(multimesh->instances);
ret.resize(multimesh->instances * multimesh->stride_cache);
{
float *w = multimesh->data_cache.ptrw();
float *w = ret.ptrw();
const uint8_t *r = buffer.ptr();
copymem(w, r, buffer.size());
}
Expand Down

0 comments on commit de465c4

Please sign in to comment.