From 74762470b2aa11a5271b846549ff14b86c1705d2 Mon Sep 17 00:00:00 2001 From: sfan5 Date: Wed, 23 Dec 2020 22:03:49 +0100 Subject: Fix some minor code issues all over the place --- src/client/mapblock_mesh.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/client/mapblock_mesh.cpp') diff --git a/src/client/mapblock_mesh.cpp b/src/client/mapblock_mesh.cpp index dac25a066..4c43fcb61 100644 --- a/src/client/mapblock_mesh.cpp +++ b/src/client/mapblock_mesh.cpp @@ -1201,13 +1201,13 @@ MapBlockMesh::MapBlockMesh(MeshMakeData *data, v3s16 camera_offset): MapBlockMesh::~MapBlockMesh() { for (scene::IMesh *m : m_mesh) { - if (m_enable_vbo && m) + if (m_enable_vbo) { for (u32 i = 0; i < m->getMeshBufferCount(); i++) { scene::IMeshBuffer *buf = m->getMeshBuffer(i); RenderingEngine::get_video_driver()->removeHardwareBuffer(buf); } + } m->drop(); - m = NULL; } delete m_minimap_mapblock; } -- cgit v1.2.3