View Single Post
Old 09-12-2011, 06:13 PM   #167
fandrieu
Member
fandrieu began at the beginning.
 
Posts: 11
Karma: 10
Join Date: Sep 2011
Device: kindle 3
Quote:
Originally Posted by KevinH View Post
I grabbed it and tried it on a bunch of mobis I had
Thanks very much for the effort you put into testing this.

The code is indeed very rough and there's more chances to get an exception than a ncx

About the "anchor" bit it was really just a wild experiment that worked for the book a was working on...

I hadn't much time to read your posts now, but you are right, the first missing thing is to take the INDX entry type into account, and not just assume 0x0F=chapter as I did to try this out.

BTW i updated the zip i posted with some "essential" stuff that was missing:
* bail if INDX entry if not 0xF (todo...)
* correctly handle end of CTOC (nul terminated)
* basic checking of the indx_header (wrong in some test files)
* ...
fandrieu is offline   Reply With Quote