]> granicus.if.org Git - python/commit
bpo-24596: Decref module in PyRun_SimpleFileExFlags() on SystemExit (GH-7918)
authorZackery Spytz <zspytz@gmail.com>
Tue, 3 Jul 2018 19:47:22 +0000 (13:47 -0600)
committerAntoine Pitrou <pitrou@free.fr>
Tue, 3 Jul 2018 19:47:22 +0000 (21:47 +0200)
commitd8cba5d16f1333fd625726fc72e66afbd45b8d00
tree6aa57f4d44036535b4cdf7895e92cd235a5b8f4f
parent831c29721dcb1b768c6315a4b8a4059c4c97ee8b
bpo-24596: Decref module in PyRun_SimpleFileExFlags() on SystemExit (GH-7918)

PyErr_Print() will not return when the exception is a SystemExit, so
decref the __main__ module object in that case.
Lib/test/test_gc.py
Misc/NEWS.d/next/Core and Builtins/2018-06-25-16-54-05.bpo-24596.Rkwova.rst [new file with mode: 0644]
Python/pythonrun.c