Mst::saveMST(): m_version should have the full character, not just an int version.

TODO: Change it from `uint8_t` to `char`?
This commit is contained in:
David Korth 2019-05-20 21:45:00 -04:00
parent 20067d3f8d
commit c50ec4b87c

View File

@ -575,7 +575,7 @@ int Mst::saveMST(FILE *fp) const
// the rest of the string table is handled. // the rest of the string table is handled.
MST_Header mst_header; MST_Header mst_header;
memset(&mst_header, 0, sizeof(mst_header)); memset(&mst_header, 0, sizeof(mst_header));
mst_header.version = m_version; mst_header.version = m_version + '@';
mst_header.endianness = (m_isBigEndian ? 'B' : 'L'); mst_header.endianness = (m_isBigEndian ? 'B' : 'L');
mst_header.bina_magic = cpu_to_be32(BINA_MAGIC); mst_header.bina_magic = cpu_to_be32(BINA_MAGIC);