Kaydet (Commit) 0eb55ac9 authored tarafından Guido van Rossum's avatar Guido van Rossum

Mark Favas was quick to note that the last checkin divides by zero

when n == 0...  So divide by a->ob_size instead which was already
tested for 0.
üst 5bc51f2f
......@@ -374,7 +374,7 @@ tuplerepeat(a, n)
return (PyObject *)a;
}
size = a->ob_size * n;
if (size/n != a->ob_size)
if (size/a->ob_size != n)
return PyErr_NoMemory();
np = (PyTupleObject *) PyTuple_New(size);
if (np == NULL)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment