1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

(se)SerializeString: Include max length in the name

This commit clarifies the maximal length of the serialized strings.
It will avoid accidental use of serializeString() when a larger string can be expected.

Removes unused Wide String serialization functions
This commit is contained in:
SmallJoker 2020-09-20 13:12:55 +02:00 committed by Loïc Blot
parent ca5c2dbefa
commit 947466ab28
23 changed files with 168 additions and 223 deletions

View file

@ -35,7 +35,7 @@ void StaticObject::serialize(std::ostream &os)
// pos
writeV3F1000(os, pos);
// data
os<<serializeString(data);
os<<serializeString16(data);
}
void StaticObject::deSerialize(std::istream &is, u8 version)
{
@ -44,7 +44,7 @@ void StaticObject::deSerialize(std::istream &is, u8 version)
// pos
pos = readV3F1000(is);
// data
data = deSerializeString(is);
data = deSerializeString16(is);
}
void StaticObjectList::serialize(std::ostream &os)