Fix T31555: Username with special chars in Windows 7

At last! Could not check seriously on windows (though it was done during py patch
process).
This commit is contained in:
Bastien Montagne 2014-05-01 16:22:30 +02:00
parent 1e9c4639c2
commit bb5b608deb
Notes: blender-bot 2023-02-14 13:36:13 +01:00
Referenced by issue #31555, Username with special chars in Windows 7
1 changed files with 1 additions and 5 deletions

View File

@ -257,11 +257,7 @@ void BPY_python_start(int argc, const char **argv)
* an error, this is highly annoying, another stumbling block for devs,
* so use a more relaxed error handler and enforce utf-8 since the rest of
* blender is utf-8 too - campbell */
/* XXX, update: this is unreliable! 'PYTHONIOENCODING' is ignored in MS-Windows
* when dynamically linked, see: [#31555] for details.
* Python doesn't expose a good way to set this. */
BLI_setenv("PYTHONIOENCODING", "utf-8:surrogateescape");
Py_SetStandardStreamEncoding("utf-8", "surrogateescape");
/* Update, Py3.3 resolves attempting to parse non-existing header */
#if 0