mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
MOBI Input: Fix regression parsing '
MOBI Input: Fix a regression that broke parsing of MOBI files with malformed markup that also used entities for apostrophes. Fixes #1197585 [Private bug](https://bugs.launchpad.net/calibre/+bug/1197585)
This commit is contained in:
parent
af26c0055c
commit
852bd49453
@ -62,7 +62,7 @@ def _parse(source, beautifulsoup, makeelement, **bsargs):
|
||||
if makeelement is None:
|
||||
makeelement = html.html_parser.makeelement
|
||||
if 'convertEntities' not in bsargs:
|
||||
bsargs['convertEntities'] = 'html'
|
||||
bsargs['convertEntities'] = 'xhtml' # Changed by Kovid, otherwise ' is mangled, see https://bugs.launchpad.net/calibre/+bug/1197585
|
||||
tree = beautifulsoup(source, **bsargs)
|
||||
root = _convert_tree(tree, makeelement)
|
||||
# from ET: wrap the document in a html root element, if necessary
|
||||
|
Loading…
x
Reference in New Issue
Block a user