summaryrefslogtreecommitdiff
path: root/src/itemdef.cpp
diff options
context:
space:
mode:
authorkwolekr <kwolekr@minetest.net>2013-04-28 21:07:09 -0400
committerkwolekr <kwolekr@minetest.net>2013-04-28 21:07:09 -0400
commitc824abd7b2e199d9c7e3dcc2839a28275f4120f2 (patch)
tree622265976972ef9ccd471d2b90121724daafc022 /src/itemdef.cpp
parentd7395cd2aba86f5b15cdce3be2ec141f88f95ab6 (diff)
downloadminetest-c824abd7b2e199d9c7e3dcc2839a28275f4120f2.tar.gz
minetest-c824abd7b2e199d9c7e3dcc2839a28275f4120f2.tar.bz2
minetest-c824abd7b2e199d9c7e3dcc2839a28275f4120f2.zip
Fix itemdef drop on NULL texture
Diffstat (limited to 'src/itemdef.cpp')
-rw-r--r--src/itemdef.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/itemdef.cpp b/src/itemdef.cpp
index 784919ae2..05328ea48 100644
--- a/src/itemdef.cpp
+++ b/src/itemdef.cpp
@@ -247,7 +247,8 @@ public:
i = values.begin(); i != values.end(); ++i)
{
ClientCached *cc = *i;
- cc->wield_mesh->drop();
+ if (cc->wield_mesh)
+ cc->wield_mesh->drop();
delete cc;
}