Mercurial > cpython-lru_cache-weakref
comparison Python/pythonrun.c @ 72976:af0800b986b7
Issue #12281: Rewrite the MBCS codec to handle correctly replace and ignore
error handlers on all Windows versions. The MBCS codec is now supporting all
error handlers, instead of only replace to encode and ignore to decode.
| author | Victor Stinner <victor.stinner@haypocalc.com> |
|---|---|
| date | Tue, 18 Oct 2011 21:21:00 +0200 |
| parents | db4aa878cea2 |
| children | fa2f8dd077e0 |
comparison
equal
deleted
inserted
replaced
| 72975:70160b53117f | 72976:af0800b986b7 |
|---|---|
| 65 static void err_free(perrdetail *); | 65 static void err_free(perrdetail *); |
| 66 static void initsigs(void); | 66 static void initsigs(void); |
| 67 static void call_py_exitfuncs(void); | 67 static void call_py_exitfuncs(void); |
| 68 static void wait_for_thread_shutdown(void); | 68 static void wait_for_thread_shutdown(void); |
| 69 static void call_ll_exitfuncs(void); | 69 static void call_ll_exitfuncs(void); |
| 70 extern void _PyUnicode_Init(void); | 70 extern int _PyUnicode_Init(void); |
| 71 extern void _PyUnicode_Fini(void); | 71 extern void _PyUnicode_Fini(void); |
| 72 extern int _PyLong_Init(void); | 72 extern int _PyLong_Init(void); |
| 73 extern void PyLong_Fini(void); | 73 extern void PyLong_Fini(void); |
| 74 extern int _PyFaulthandler_Init(void); | 74 extern int _PyFaulthandler_Init(void); |
| 75 extern void _PyFaulthandler_Fini(void); | 75 extern void _PyFaulthandler_Fini(void); |
| 259 interp->modules_reloading = PyDict_New(); | 259 interp->modules_reloading = PyDict_New(); |
| 260 if (interp->modules_reloading == NULL) | 260 if (interp->modules_reloading == NULL) |
| 261 Py_FatalError("Py_Initialize: can't make modules_reloading dictionary"); | 261 Py_FatalError("Py_Initialize: can't make modules_reloading dictionary"); |
| 262 | 262 |
| 263 /* Init Unicode implementation; relies on the codec registry */ | 263 /* Init Unicode implementation; relies on the codec registry */ |
| 264 _PyUnicode_Init(); | 264 if (_PyUnicode_Init() < 0) |
| 265 Py_FatalError("Py_Initialize: can't initialize unicode"); | |
| 265 | 266 |
| 266 bimod = _PyBuiltin_Init(); | 267 bimod = _PyBuiltin_Init(); |
| 267 if (bimod == NULL) | 268 if (bimod == NULL) |
| 268 Py_FatalError("Py_Initialize: can't initialize builtins modules"); | 269 Py_FatalError("Py_Initialize: can't initialize builtins modules"); |
| 269 _PyImport_FixupBuiltin(bimod, "builtins"); | 270 _PyImport_FixupBuiltin(bimod, "builtins"); |
