quote:
Originally posted by CookieRevised
This implies also that you can't jump easly to a certain part of the file/chunck without checking these null-terminated strings and this is, IMO, a bit messy
yes yes yes, you're completly right.... I didn't think about that
. I suggest puttung the member Data length at the begining of the chunk and it should be the whole chunk length. Imo, I still think that null-terminated strings are better than pascal-style strings. Most programming languages and OSes use those kind of strings and it's not very complicated to skip the name and comments fields by searching null chars (even if you need to read all the bytes). Note that putting the data lenght at the begining if you're reading the comments that's because you need the data of the chunk and so you may need (very probably) the whole chunk (with its name and comments). So at the same time you're reading the comments too.