HTML Input: Remove the # character from input filesnames, for maximum compatibility. Fixes #1656833 [Ebook-convert creates unreadable epub if there's a hash in the filename](https://bugs.launchpad.net/calibre/+bug/1656833)

This commit is contained in:
Kovid Goyal 2017-01-17 18:08:33 +05:30
parent e15e3383b0
commit 6f18070861

View File

@ -20,7 +20,7 @@ from calibre.utils.imghdr import what
def sanitize_file_name(x):
return re.sub(r'[?&=;]', '_', ascii_filename(x))
return re.sub(r'[?&=;#]', '_', ascii_filename(x))
class HTMLInput(InputFormatPlugin):
@ -312,4 +312,3 @@ class HTMLInput(InputFormatPlugin):
self.log.exception('Failed to read CSS file: %r'%link)
return (None, None)
return (None, raw)