mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
...
This commit is contained in:
parent
d92200eaba
commit
fede595e87
@ -384,7 +384,10 @@ class LinuxFreeze(Command):
|
||||
except:
|
||||
print ('WARNING: Failed to set default libc locale, using en_US.UTF-8')
|
||||
locale.setlocale(locale.LC_ALL, 'en_US.UTF-8')
|
||||
try:
|
||||
enc = locale.getdefaultlocale()[1]
|
||||
except Exception:
|
||||
enc = None
|
||||
if not enc:
|
||||
enc = locale.nl_langinfo(locale.CODESET)
|
||||
if not enc or enc.lower() == 'ascii':
|
||||
|
Loading…
x
Reference in New Issue
Block a user