]> granicus.if.org Git - python/commitdiff
One too many decrefs.
authorRaymond Hettinger <python@rcn.com>
Wed, 27 Feb 2008 01:08:04 +0000 (01:08 +0000)
committerRaymond Hettinger <python@rcn.com>
Wed, 27 Feb 2008 01:08:04 +0000 (01:08 +0000)
Modules/itertoolsmodule.c

index 10c5e0bdbd86a5e7bed5603cea6e668ed8cf6199..4efde75b62804b97a29bc92c86c9ca7914540779 100644 (file)
@@ -1794,10 +1794,8 @@ product_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
 
        /* create productobject structure */
        lz = (productobject *)type->tp_alloc(type, 0);
-       if (lz == NULL) {
-               Py_DECREF(pools);
+       if (lz == NULL)
                goto error;
-       }
 
        lz->pools = pools;
        lz->maxvec = maxvec;