safety fix
authorStefan Behnel <scoder@users.berlios.de>
Tue, 2 Sep 2008 09:17:48 +0000 (11:17 +0200)
committerStefan Behnel <scoder@users.berlios.de>
Tue, 2 Sep 2008 09:17:48 +0000 (11:17 +0200)
Cython/Compiler/Nodes.py

index f3b5bd98968b3d439ac0739224b129cddee661cd..2738fd6658d6170f0af528c0e61329b460f2fb6e 100644 (file)
@@ -4881,11 +4881,9 @@ void INLINE __Pyx_ExceptionSave(PyObject **type, PyObject **value, PyObject **tb
     *type = tstate->exc_type;
     *value = tstate->exc_value;
     *tb = tstate->exc_traceback;
-    if (*type) {
-        Py_INCREF(*type);
-        Py_XINCREF(*value);
-        Py_XINCREF(*tb);
-    }
+    Py_XINCREF(*type);
+    Py_XINCREF(*value);
+    Py_XINCREF(*tb);
 }
 
 void __Pyx_ExceptionReset(PyObject *type, PyObject *value, PyObject *tb) {