New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
KOReader crashes when opening epub with embedded fonts #6394
Comments
Thanks. Reproduced:
Involves a new method I added in koreader/crengine@ff3640d |
@Frenzie : I have some fix for this (and #6391). Not really sure when this crash triggers, as it doesn't on some of my books with embedded fonts - but it surely will on some books. |
@poire-z If it's grave enough, sure. PS I was seconds away from clicking publish. |
I don't know how grave - it's the first report since 14th days the impacting change is in our nightlies :) |
And… published. ;-) |
OK, I believe this crash should be rare. The book needs to have embedded font defined in the <html xmlns="http://www.w3.org/1999/xhtml" xmlns:epub="http://www.idpf.org/2007/ops" lang="en-US" xml:lang="en-US">
<head>
<title>Scrambled</title>
<style>
@font-face {font-family: 'Shift Light'; font-style: normal; font-weight: bold; src: url('../Fonts/Shift-Bold.otf');}
@font-face {font-family: 'Shift Light'; font-style: italic; font-weight: bold; src: url('../Fonts/Shift-BoldItalic.otf');} Most books have them defined in some |
Seems like it affects about 10% of the 200 or so books on my Kobo so not that rare, but I can work around it with Calibre. |
Issue
When opening some ePub with embedded fonts, KOReader crashes with the following message:
CRE: document loaded, but styles re-init needed (cause: embedded fonts) CRE: styles re-init needed after load, re-rendering Segmentation fault !!!! Uh oh, something went awry... (Crash n°1: 07/19/20 @ 14:03:07)
If I open the epub with the stable release v2020.06 the book opens fine.
If I remove the embedded font information with Calibre the book also opens fine in v2020.06-60.
Steps to reproduce
Open attached embedded_font_crash_scrambled.epub file
embedded_font_crash_scrambled.zip
crash.log
(if applicable)crash.log
The text was updated successfully, but these errors were encountered: