View Single Post
Old 10-24-2011, 11:45 AM   #424
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 28,445
Karma: 203720150
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
Originally Posted by adriantc View Post
So where is the problem... in Mobi2Mobi or Calibre?
I'm just not sure. The source (for the most recent version of calibre) that writes the Palmdoc header seems pretty straightforward and would appear to always create a database name that is 32 characters or less and null terminated.
Code:
title = str(self._oeb.metadata.title[0])
title = re.sub('[^-A-Za-z0-9]+', '_', title)[:31]
title = title + ('\0' * (32 - len(title)))
So either:
A) something screwy is happening in calibre that causes the null termination to fail on longer titles.

B) mobi2mobi doesn't think the string is null terminated for some reason.

To be perfectly honest... neither seem very likely to me. I'm a little stymied.
DiapDealer is offline   Reply With Quote