mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
bpo-36142: _PyPreConfig_Read() sets LC_CTYPE (GH-12188)
* _PyPreConfig_Read() now sets temporarily LC_CTYPE to the user preferred locale, as _PyPreConfig_Write() will do permanentely. * Fix _PyCoreConfig_Clear(): clear run_xxx attributes * _Py_SetArgcArgv() doesn't have to be exported * _PyCoreConfig_SetGlobalConfig() no longer applies preconfig
This commit is contained in:
parent
c656e25667
commit
4fffd380a4
4 changed files with 78 additions and 47 deletions
|
@ -716,9 +716,6 @@ _Py_InitializeCore_impl(PyInterpreterState **interp_p,
|
|||
static _PyInitError
|
||||
pyinit_preconfig(_PyPreConfig *preconfig, const _PyPreConfig *src_preconfig)
|
||||
{
|
||||
/* Set LC_CTYPE to the user preferred locale */
|
||||
_Py_SetLocaleFromEnv(LC_CTYPE);
|
||||
|
||||
if (_PyPreConfig_Copy(preconfig, src_preconfig) < 0) {
|
||||
return _Py_INIT_ERR("failed to copy pre config");
|
||||
}
|
||||
|
@ -736,10 +733,6 @@ static _PyInitError
|
|||
pyinit_coreconfig(_PyCoreConfig *config, const _PyCoreConfig *src_config,
|
||||
PyInterpreterState **interp_p)
|
||||
{
|
||||
|
||||
/* Set LC_CTYPE to the user preferred locale */
|
||||
_Py_SetLocaleFromEnv(LC_CTYPE);
|
||||
|
||||
if (_PyCoreConfig_Copy(config, src_config) < 0) {
|
||||
return _Py_INIT_ERR("failed to copy core config");
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue