Index: Python/pythonrun.c =================================================================== --- Python/pythonrun.c (révision 78770) +++ Python/pythonrun.c (copie de travail) @@ -284,8 +284,13 @@ loc_codeset = strdup(loc_codeset); Py_DECREF(enc); } else { - loc_codeset = NULL; - PyErr_Clear(); + if (PyErr_ExceptionMatches(PyExc_LookupError)) { + PyErr_Clear(); + loc_codeset = NULL; + } else { + PyErr_Print(); + exit(1); + } } } else loc_codeset = NULL;