summaryrefslogtreecommitdiffstats
path: root/Objects
diff options
context:
space:
mode:
Diffstat (limited to 'Objects')
-rw-r--r--Objects/genobject.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/Objects/genobject.c b/Objects/genobject.c
index a3eae6a..7cec290 100644
--- a/Objects/genobject.c
+++ b/Objects/genobject.c
@@ -217,10 +217,8 @@ gen_throw(PyGenObject *gen, PyObject *args)
/* First, check the traceback argument, replacing None with
NULL. */
- if (tb == Py_None) {
- Py_DECREF(tb);
+ if (tb == Py_None)
tb = NULL;
- }
else if (tb != NULL && !PyTraceBack_Check(tb)) {
PyErr_SetString(PyExc_TypeError,
"throw() third argument must be a traceback object");