fallahn/tmxlite

Crashes loading tmx files from version 1.4.0

ralf-zenker opened this issue · 5 comments

Worked perfectly with the same tmx file from version 1.3.x but crashes when saved with 1.4.0.

if (name == "tileset")
{
m_tilesets.emplace_back(m_workingDirectory);
m_tilesets.back().parse(node, this);
}

It crashes in the parse function.

I can't reproduce this with maps saved with Tiled 1.4.1. Are you using a release version of tmxlite or the head revision? Can you provide a simple map which reproduces the crash? Thanks!

Hi @fallahn, i see the same issue.
This is the first time i use your library, for that i do not know if is replicable with other version of Tiled.

For debuging the library crash on void Tileset::createMissingTile(std::uint32_t ID) -> m_tiles.push_back(tile); (line: 395, file tileset.cpp)

faultInput.zip
(Versione used Tiled 1.4.2)

Thanks for leaving an example map. I'll look into this.

So the first thing I notice is that Tiled now supports a new compression format called zstd, which miniz can't decompress. Could you try converting your map to use zlib compression and see if the crash still happens? I've also not managed to reproduce the crash on the line you stated when using the ParseTest project included in the repo. Are you using a release version of tmxlite or the latest revision? If not could you please try the latest revision to see if it works for you? Thanks.

Hi @fallahn, i update form the release of yesterday to the last one and changed the compression in tmx file.
The issue, is not present anymore
Thanks