Re: [hatari-devel] memory snapshot format/issues

[ Thread Index | Date Index | More lists.tuxfamily.org/hatari-devel Archives ]


Le 08/05/2015 23:40, Eero Tamminen a écrit :

Older version would do strcmp() for strings with lengths of 6 & 7 bytes.
First 6 chars will obviously be different so it doesn't try to load
wrong version.

I would also assume that strcmp() stops at first differing
character, so loading 6 bytes of 7 byte string shouldn't be
a problem in practice.

However, I checked memorysnapShot.c history, and earlier versions
try to print out the on-disk snapshot version, which would now
be missing the terminating NULL, which could cause issues
(at least mess up terminal with non-printable characters).

So, the new format snapshot identification file format should
have '\0' within first 6 characters.

Yes, that's the problem if we want to use "1.10.0" for example, with only 6 characters we're limited to "1.10.\0", so we can't use "1.10.1" anymore.





Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/