Kaydet (Commit) 418fd74f authored tarafından Christian Heimes's avatar Christian Heimes

Issue #23998: PyImport_ReInitLock() now checks for lock allocation error

üst e5a853c3
......@@ -32,6 +32,11 @@ Library
- Issue #23365: Fixed possible integer overflow in
itertools.combinations_with_replacement.
C API
-----
- Issue #23998: PyImport_ReInitLock() now checks for lock allocation error
What's New in Python 3.3.6?
===========================
......
......@@ -199,8 +199,12 @@ _PyImport_ReleaseLock(void)
void
_PyImport_ReInitLock(void)
{
if (import_lock != NULL)
if (import_lock != NULL) {
import_lock = PyThread_allocate_lock();
if (import_lock == NULL) {
Py_FatalError("PyImport_ReInitLock failed to create a new lock");
}
}
if (import_lock_level > 1) {
/* Forked as a side effect of import */
long me = PyThread_get_thread_ident();
......
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