summaryrefslogtreecommitdiff
path: root/Objects
diff options
context:
space:
mode:
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>2018-10-31 02:31:29 -0700
committerGitHub <noreply@github.com>2018-10-31 02:31:29 -0700
commitda15389fddb85cf8a97b81e75de7d77b5f505b56 (patch)
tree488539656f842787c387b6fecbe2242e71f24763 /Objects
parentb183750f999953bac7738b1fff114e0a2615d970 (diff)
downloadcpython-git-da15389fddb85cf8a97b81e75de7d77b5f505b56.tar.gz
Fix a possible crash in range.__reversed__(). (GH-10252)
(cherry picked from commit c9a6168924ffa4f3f78175998b392fe23d3edc50) Co-authored-by: Zackery Spytz <zspytz@gmail.com>
Diffstat (limited to 'Objects')
-rw-r--r--Objects/rangeobject.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/Objects/rangeobject.c b/Objects/rangeobject.c
index e4f778b1f8..037be870e3 100644
--- a/Objects/rangeobject.c
+++ b/Objects/rangeobject.c
@@ -1154,6 +1154,7 @@ long_range:
it = PyObject_New(longrangeiterobject, &PyLongRangeIter_Type);
if (it == NULL)
return NULL;
+ it->index = it->start = it->step = NULL;
/* start + (len - 1) * step */
it->len = range->length;