Fix itemdef drop on NULL texture
authorkwolekr <kwolekr@minetest.net>
Mon, 29 Apr 2013 01:07:09 +0000 (21:07 -0400)
committerkwolekr <kwolekr@minetest.net>
Mon, 29 Apr 2013 01:07:09 +0000 (21:07 -0400)
src/itemdef.cpp

index 784919ae2deb371732118e6943511519c2be6c1d..05328ea486e4f85118625981330ce5cbedda3d91 100644 (file)
@@ -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;
                }