mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-05-08 17:43:38 +02:00
Fix #401
This commit is contained in:
parent
3029d1f164
commit
e97b762bdf
1 changed files with 2 additions and 2 deletions
|
|
@ -171,7 +171,7 @@ def get_font_families():
|
|||
def sanitize_file_name(name):
|
||||
'''
|
||||
Remove characters that are illegal in filenames from name.
|
||||
Also remove path separators. ALl illegal characters are replaced by
|
||||
Also remove path separators. All illegal characters are replaced by
|
||||
underscores.
|
||||
'''
|
||||
return re.sub(r'\s', ' ', re.sub(r'[\|\~\:\?\\\/]|^-', '_', name.strip()))
|
||||
return re.sub(r'\s', ' ', re.sub(r'["\'\|\~\:\?\\\/]|^-', '_', name.strip()))
|
||||
Loading…
Reference in a new issue