From 626dae7a4269a9d2f3708e57080995cbf60289eb Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Fri, 10 Jan 1992 00:28:07 +0000 Subject: [PATCH] Fix bug in assign_slice for negative index; used length of wrong object! --- Python/ceval.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Python/ceval.c b/Python/ceval.c index ec241105b1a..1d0cdb46e8b 100644 --- a/Python/ceval.c +++ b/Python/ceval.c @@ -1592,7 +1592,7 @@ assign_subscript(w, key, v) /* w[key] = v */ else { int i = getintvalue(key); if (i < 0) - i += (*sq->sq_length)(v); + i += (*sq->sq_length)(w); return (*func)(w, i, v); } }