projects
/
oweals
/
minetest.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
If there was no source item in a furnace it would cause a segmentation fault.
[oweals/minetest.git]
/
src
/
inventory.cpp
diff --git
a/src/inventory.cpp
b/src/inventory.cpp
index 62aedb536aee407b4309706c8b4b8c1b2c36c3aa..116ceeb6df3a838fb06c06ac4a817878d4625eef 100644
(file)
--- a/
src/inventory.cpp
+++ b/
src/inventory.cpp
@@
-581,6
+581,8
@@
bool InventoryList::roomForItem(const InventoryItem *item)
bool InventoryList::roomForCookedItem(const InventoryItem *item)
{
+ if(!item)
+ return false;
const InventoryItem *cook = item->createCookResult();
if(!cook)
return false;