forked from Mirrorlandia_minetest/minetest
Fix for empty key/value when reading item string with wear but no metadata (#6058)
This commit is contained in:
parent
d7343b6c93
commit
85d7b18d85
@ -28,7 +28,8 @@ void ItemStackMetadata::deSerialize(std::istream &is)
|
||||
|
||||
m_stringvars.clear();
|
||||
|
||||
if (!in.empty() && in[0] == DESERIALIZE_START) {
|
||||
if (!in.empty()) {
|
||||
if (in[0] == DESERIALIZE_START) {
|
||||
Strfnd fnd(in);
|
||||
fnd.to(1);
|
||||
while (!fnd.at_end()) {
|
||||
@ -41,3 +42,4 @@ void ItemStackMetadata::deSerialize(std::istream &is)
|
||||
m_stringvars[""] = in;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user