mirror of
https://github.com/moparisthebest/minetest
synced 2025-01-11 05:38:01 -05:00
src/wieldmesh.cpp: Fix mesh extrusion memory leak
This commit is contained in:
parent
ebe7b31538
commit
c4287a0d68
@ -114,8 +114,9 @@ static scene::IMesh* createExtrusionMesh(int resolution_x, int resolution_y)
|
|||||||
mesh->addMeshBuffer(buf);
|
mesh->addMeshBuffer(buf);
|
||||||
buf->drop();
|
buf->drop();
|
||||||
scaleMesh(mesh, scale); // also recalculates bounding box
|
scaleMesh(mesh, scale); // also recalculates bounding box
|
||||||
mesh = (scene::SMesh *)createForsythOptimizedMesh(mesh);
|
scene::IMesh *newmesh = createForsythOptimizedMesh(mesh);
|
||||||
return mesh;
|
mesh->drop();
|
||||||
|
return newmesh;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Loading…
Reference in New Issue
Block a user