mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-22 10:00:33 +00:00
Get the file system encoding from sys instead of the locale
This commit is contained in:
parent
67bf174b10
commit
dc7ac99d18
@ -196,10 +196,7 @@ def checkTeXPaths():
|
|||||||
from tempfile import mkstemp
|
from tempfile import mkstemp
|
||||||
fd, tmpfname = mkstemp(suffix='.ltx')
|
fd, tmpfname = mkstemp(suffix='.ltx')
|
||||||
if os.name == 'nt':
|
if os.name == 'nt':
|
||||||
from locale import getdefaultlocale
|
encoding = sys.getfilesystemencoding()
|
||||||
language, encoding = getdefaultlocale()
|
|
||||||
if encoding == None:
|
|
||||||
encoding = 'latin1'
|
|
||||||
if sys.version_info[0] < 3:
|
if sys.version_info[0] < 3:
|
||||||
inpname = shortPath(unicode(tmpfname, encoding)).replace('\\', '/')
|
inpname = shortPath(unicode(tmpfname, encoding)).replace('\\', '/')
|
||||||
else:
|
else:
|
||||||
|
Loading…
Reference in New Issue
Block a user