Unverified Kaydet (Commit) ac14632c authored tarafından Steve Dower's avatar Steve Dower Kaydeden (comit) GitHub

bpo-37369: Fixes crash when reporting fatal error (GH-14468)

üst 9048c493
......@@ -166,12 +166,12 @@ wmain(int argc, wchar_t **argv)
PyPreConfig_InitPythonConfig(&preconfig);
status = Py_PreInitializeFromArgs(&preconfig, argc, argv);
if (PyStatus_Exception(status)) {
goto fail;
goto fail_without_config;
}
status = PyConfig_InitPythonConfig(&config);
if (PyStatus_Exception(status)) {
goto fail;
goto fail_without_config;
}
status = PyConfig_SetArgv(&config, argc, argv);
......@@ -233,6 +233,7 @@ wmain(int argc, wchar_t **argv)
fail:
PyConfig_Clear(&config);
fail_without_config:
if (PyStatus_IsExit(status)) {
return status.exitcode;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment