[Python-checkins] cpython (3.3): avoid referencing past the bounds of an array
benjamin.peterson
python-checkins at python.org
Sat Mar 15 18:22:03 CET 2014
http://hg.python.org/cpython/rev/f5e9495df22f
changeset: 89668:f5e9495df22f
branch: 3.3
parent: 89666:3f93907ab8e1
user: Benjamin Peterson <benjamin at python.org>
date: Sat Mar 15 12:21:28 2014 -0500
summary:
avoid referencing past the bounds of an array
files:
Objects/listobject.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/Objects/listobject.c b/Objects/listobject.c
--- a/Objects/listobject.c
+++ b/Objects/listobject.c
@@ -1963,7 +1963,7 @@
if (keys[i] == NULL) {
for (i=i-1 ; i>=0 ; i--)
Py_DECREF(keys[i]);
- if (keys != &ms.temparray[saved_ob_size+1])
+ if (saved_ob_size >= MERGESTATE_TEMP_SIZE/2)
PyMem_FREE(keys);
goto keyfunc_fail;
}
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list