Fixed potential NULL incref

This commit is contained in:
Daniele Varrazzo 2012-02-23 19:47:36 +00:00
parent 1b27820389
commit 7d67ecbed3

View File

@ -710,7 +710,7 @@ psyco_GetDecimalType(void)
}
/* Store the object from future uses. */
if (can_cache && !cachedType) {
if (can_cache && !cachedType && decimalType) {
Py_INCREF(decimalType);
cachedType = decimalType;
}