mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
EPUB Input: Workaround for invalid EPUBs produced by someone named 'ibooks, Inc.'. Fixes #744122 (Conversion of epub failed)
This commit is contained in:
parent
e6cb34d600
commit
517a8d82cd
@ -103,8 +103,8 @@ class OEBReader(object):
|
||||
data = self.oeb.container.read(None)
|
||||
data = self.oeb.decode(data)
|
||||
data = XMLDECL_RE.sub('', data)
|
||||
data = data.replace('http://openebook.org/namespaces/oeb-package/1.0',
|
||||
OPF1_NS)
|
||||
data = re.sub(r'http://openebook.org/namespaces/oeb-package/1.0(/*)',
|
||||
OPF1_NS, data)
|
||||
try:
|
||||
opf = etree.fromstring(data)
|
||||
except etree.XMLSyntaxError:
|
||||
|
Loading…
x
Reference in New Issue
Block a user