error handling fix in metaclass utility code
authorStefan Behnel <scoder@users.berlios.de>
Mon, 8 Nov 2010 18:30:57 +0000 (19:30 +0100)
committerStefan Behnel <scoder@users.berlios.de>
Mon, 8 Nov 2010 18:30:57 +0000 (19:30 +0100)
Cython/Compiler/ExprNodes.py

index 48b48badb6ab54d188d5191093bc022ea3fd2fb1..c93546c9ccc324fef2e8c229da86f70e1b2dbcd4 100755 (executable)
@@ -7276,6 +7276,8 @@ static PyObject *__Pyx_CreateClass(PyObject *bases, PyObject *dict, PyObject *na
     }
     if (mkw && PyDict_Size(mkw) > 0) {
         PyObject *margs = PyTuple_New(3);
+        if (!margs)
+            goto bad;
         Py_INCREF(name);
         Py_INCREF(bases);
         Py_INCREF(dict);