FBReader icon indicating copy to clipboard operation
FBReader copied to clipboard

tex4ebook makes epubs that crash fbreader

Open DavidGriffith opened this issue 10 years ago • 7 comments

I don't know if this is a problem with tex4ebook or fbreader, so I'm posting this as an issue for both projects. Given the following input latex processed with tex4ebook,

\documentclass[12pt]{book}
\parindent=0pt
\parskip=7pt
\begin{document}
\newpage
blah blah blah
\newpage
\end{document}

the resulting epub file causes fbreader 0.99.4 (the latest) to crash like this:

$ fbreader test.epub 
terminate called after throwing an instance of 'std::out_of_range'
  what():  basic_string::substr
Aborted

Then if I run just fbreader, I get a blank window with just the toolbar across the top.

I couldn't get the latest git of fbreader (7abc80d12fab06b05ea1fe68a0e73ea5e9486463) to work in any fashion.

DavidGriffith avatar Mar 24 '14 03:03 DavidGriffith

Could you please attach (or send to [email protected]) produced ePub? I have no tex4ebook at this moment (and no linux computer to install it quickly).

geometer avatar Mar 24 '14 03:03 geometer

Sent. Anyone else can find the file at http://661.org/tmp/test.epub

DavidGriffith avatar Mar 24 '14 21:03 DavidGriffith

Thanks. I cannot test it on desktop right now, tested on android. Not sure this is related to the original issue, but OEBPS/test.ncx is not a valid XML. Empty line at start + playOrder attribute with no quotes.

geometer avatar Mar 24 '14 22:03 geometer

Wow, and content.opf too: extra space at start of file.

geometer avatar Mar 24 '14 22:03 geometer

Yes, after fixing these issues it works well on my phone. (Android version uses same native engine for file parsing as desktop version.)

geometer avatar Mar 24 '14 22:03 geometer

Anyway, the crash should be fixed, so I to not close the issue.

geometer avatar Mar 24 '14 22:03 geometer

I sent you another epub. This one works on 0.12.10, but not 0.99.4.

DavidGriffith avatar Mar 25 '14 06:03 DavidGriffith