]> granicus.if.org Git - python/commit
Fix memleak in os.getrandom()
authorVictor Stinner <victor.stinner@gmail.com>
Tue, 20 Sep 2016 21:00:59 +0000 (23:00 +0200)
committerVictor Stinner <victor.stinner@gmail.com>
Tue, 20 Sep 2016 21:00:59 +0000 (23:00 +0200)
commitec2319c46d11e8f486e7def785339af5415a3559
treee07dfd50ae27a470fade7c623d2deac6c9fb91c3
parent75024c6589539f72af69ce61cd6493b193989c2d
Fix memleak in os.getrandom()

Issue #27778: Fix a memory leak in os.getrandom() when the getrandom() is
interrupted by a signal and a signal handler raises a Python exception.

Modify also os_getrandom_impl() to avoid the temporary buffer, use directly a
Python bytes object.
Misc/NEWS
Modules/posixmodule.c