From: Andrew M. Kuchling Date: Thu, 28 Sep 2006 17:05:18 +0000 (+0000) Subject: [Backport rev. 39012 by mwh] X-Git-Tag: v2.4.4c1~101 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c91fb6fc7aabca27bf8d4d6c739819dd448d5689;p=thirdparty%2FPython%2Fcpython.git [Backport rev. 39012 by mwh] Add a missing incref. --- diff --git a/Misc/NEWS b/Misc/NEWS index 28bc76a973e5..2d5e60cfc972 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -54,6 +54,8 @@ Core and builtins Extension Modules ----------------- +- threadmodule: add a missing incref. + - Bug #1551427: fix a wrong NULL pointer check in the win32 version of os.urandom(). diff --git a/Modules/threadmodule.c b/Modules/threadmodule.c index 831da13c53f0..000a1151900e 100644 --- a/Modules/threadmodule.c +++ b/Modules/threadmodule.c @@ -661,6 +661,7 @@ initthread(void) Py_INCREF(&Locktype); PyDict_SetItemString(d, "LockType", (PyObject *)&Locktype); + Py_INCREF(&localtype); if (PyModule_AddObject(m, "_local", (PyObject *)&localtype) < 0) return;