diff --git a/src/calibre/ebooks/docx/fonts.py b/src/calibre/ebooks/docx/fonts.py index 4d85968272..de118fb514 100644 --- a/src/calibre/ebooks/docx/fonts.py +++ b/src/calibre/ebooks/docx/fonts.py @@ -189,7 +189,7 @@ class Fonts(object): if not is_truetype_font(prefix): return None ext = 'otf' if prefix.startswith(b'OTTO') else 'ttf' - fname = ascii_filename('%s - %s.%s' % (name, variant, ext)) + fname = ascii_filename('%s - %s.%s' % (name, variant, ext)).replace(' ', '_') with open(os.path.join(dest_dir, fname), 'wb') as dest: dest.write(prefix) dest.write(raw[32:])