mirror of
https://github.com/python/cpython.git
synced 2025-08-03 16:39:00 +00:00
bpo-36356: pymain_exit_error() only call pymain_free() for exit (GH-12968)
Add _Py_INIT_HAS_EXITCODE() macro.
This commit is contained in:
parent
00db7c73af
commit
4cb525a1f0
3 changed files with 10 additions and 3 deletions
|
@ -2172,7 +2172,7 @@ Py_FatalError(const char *msg)
|
|||
void _Py_NO_RETURN
|
||||
_Py_ExitInitError(_PyInitError err)
|
||||
{
|
||||
if (err.exitcode >= 0) {
|
||||
if (_Py_INIT_HAS_EXITCODE(err)) {
|
||||
exit(err.exitcode);
|
||||
}
|
||||
else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue