diff options
Diffstat (limited to 'Objects')
-rw-r--r-- | Objects/listobject.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Objects/listobject.c b/Objects/listobject.c index 2cb08d3..45b0951 100644 --- a/Objects/listobject.c +++ b/Objects/listobject.c @@ -421,7 +421,7 @@ list_repeat(PyListObject *a, int n) if (n < 0) n = 0; size = a->ob_size * n; - if (size/a->ob_size != n) + if (n && size/n != a->ob_size) return PyErr_NoMemory(); np = (PyListObject *) PyList_New(size); if (np == NULL) |