mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-31 14:33:54 -04:00
Fix #7355 (Adding HTML books has a problem (book is truncated))
This commit is contained in:
parent
c36178d51a
commit
a35934286a
@ -787,6 +787,8 @@ class Manifest(object):
|
||||
# Convert to Unicode and normalize line endings
|
||||
data = self.oeb.decode(data)
|
||||
data = self.oeb.html_preprocessor(data)
|
||||
# There could be null bytes in data if it had � entities in it
|
||||
data = data.replace('\0', '')
|
||||
|
||||
# Remove DOCTYPE declaration as it messes up parsing
|
||||
# In particular, it causes tostring to insert xmlns
|
||||
|
Loading…
x
Reference in New Issue
Block a user