summaryrefslogtreecommitdiffstats
path: root/Include
diff options
context:
space:
mode:
authorVictor Stinner <vstinner@redhat.com>2019-05-20 15:16:38 (GMT)
committerGitHub <noreply@github.com>2019-05-20 15:16:38 (GMT)
commit0f72147ce2b3d65235b41eddc6a57be40237b5c7 (patch)
treeffab92ed1baf4ff593145661b513e18cc7c8bb88 /Include
parent522ccef8690970fc4f78f51a3adb995f2547871a (diff)
downloadcpython-0f72147ce2b3d65235b41eddc6a57be40237b5c7.zip
cpython-0f72147ce2b3d65235b41eddc6a57be40237b5c7.tar.gz
cpython-0f72147ce2b3d65235b41eddc6a57be40237b5c7.tar.bz2
bpo-36763: Fix _PyRuntime.preconfig.coerce_c_locale (GH-13444)
_PyRuntime.preconfig.coerce_c_locale can now be used to check if the C locale has been coerced. * Fix _Py_LegacyLocaleDetected(): don't attempt to coerce the C locale if LC_ALL environment variable is set. Add 'warn' parameter: emit_stderr_warning_for_legacy_locale() must not the LC_ALL env var. * _PyPreConfig_Write() sets coerce_c_locale to 0 if _Py_CoerceLegacyLocale() fails.
Diffstat (limited to 'Include')
-rw-r--r--Include/cpython/pylifecycle.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/Include/cpython/pylifecycle.h b/Include/cpython/pylifecycle.h
index 1e1dabe..ba56664 100644
--- a/Include/cpython/pylifecycle.h
+++ b/Include/cpython/pylifecycle.h
@@ -69,8 +69,8 @@ PyAPI_FUNC(int) _PyOS_URandom(void *buffer, Py_ssize_t size);
PyAPI_FUNC(int) _PyOS_URandomNonblock(void *buffer, Py_ssize_t size);
/* Legacy locale support */
-PyAPI_FUNC(void) _Py_CoerceLegacyLocale(int warn);
-PyAPI_FUNC(int) _Py_LegacyLocaleDetected(void);
+PyAPI_FUNC(int) _Py_CoerceLegacyLocale(int warn);
+PyAPI_FUNC(int) _Py_LegacyLocaleDetected(int warn);
PyAPI_FUNC(char *) _Py_SetLocaleFromEnv(int category);
#ifdef __cplusplus