summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYury Selivanov <yury@magic.io>2016-09-09 06:38:21 (GMT)
committerYury Selivanov <yury@magic.io>2016-09-09 06:38:21 (GMT)
commit50c584f50bea9a292337a5e8693428277408060b (patch)
tree6a0c88aec50e33a117932461480da2109a32e7a5
parenteb6364557f9bc4e6be29bb8a8f43308a0e080aba (diff)
downloadcpython-50c584f50bea9a292337a5e8693428277408060b.zip
cpython-50c584f50bea9a292337a5e8693428277408060b.tar.gz
cpython-50c584f50bea9a292337a5e8693428277408060b.tar.bz2
ceval: tighten the code of STORE_ANNOTATION
-rw-r--r--Python/ceval.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/Python/ceval.c b/Python/ceval.c
index f737a2f..75ec7b2 100644
--- a/Python/ceval.c
+++ b/Python/ceval.c
@@ -1921,11 +1921,10 @@ _PyEval_EvalFrameDefault(PyFrameObject *f, int throwflag)
err = PyObject_SetItem(ann_dict, name, ann);
}
Py_DECREF(ann_dict);
+ Py_DECREF(ann);
if (err != 0) {
- Py_DECREF(ann);
goto error;
}
- Py_DECREF(ann);
DISPATCH();
}