mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-13 08:35:20 +02:00
Fix builtin inventory list crash when size = 0 (#7297)
This commit is contained in:
@@ -141,7 +141,7 @@ void RemotePlayer::deSerialize(std::istream &is, const std::string &playername,
|
||||
|
||||
inventory.deSerialize(is);
|
||||
|
||||
if (inventory.getList("craftpreview") == NULL) {
|
||||
if (!inventory.getList("craftpreview") && inventory.getList("craftresult")) {
|
||||
// Convert players without craftpreview
|
||||
inventory.addList("craftpreview", 1);
|
||||
|
||||
|
Reference in New Issue
Block a user