Commit ac456a18 authored by Antoine Pitrou's avatar Antoine Pitrou

Fix some of the remaining test_capi leaks

parent 8b0a74e9
...@@ -2400,9 +2400,11 @@ _PyExc_Init(void) ...@@ -2400,9 +2400,11 @@ _PyExc_Init(void)
POST_INIT(BytesWarning) POST_INIT(BytesWarning)
POST_INIT(ResourceWarning) POST_INIT(ResourceWarning)
if (!errnomap) {
errnomap = PyDict_New(); errnomap = PyDict_New();
if (!errnomap) if (!errnomap)
Py_FatalError("Cannot allocate map from errnos to OSError subclasses"); Py_FatalError("Cannot allocate map from errnos to OSError subclasses");
}
/* OSError subclasses */ /* OSError subclasses */
POST_INIT(ConnectionError); POST_INIT(ConnectionError);
......
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