Skip to content
  • Volker Krause's avatar
    Fix string length computation for O5M encoding · 507171b5
    Volker Krause authored and Torsten Rahn's avatar Torsten Rahn committed
    We need to consider the UTF-8 encoded string length here, which can differ
    from the QString length previously used. In most cases the difference isn't
    relevant, but I have encountered two tiles so far where those values not
    only differed, but ended up on either side of the 250 character limit here.
    If that happens the string table in the o5m decoder when reading this ends
    up in an inconsistent state, and produces spectacularly messed up tags.
    
    While at it, also sharpen the asserts here, violating either of those would
    produce invalid o5m output.
    507171b5