Message254367
| Author |
Jim Nasby |
| Recipients |
Jim Nasby |
| Date |
2015年11月09日.05:44:34 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1447047875.1.0.253447135487.issue25587@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
In PyTuple_New, if the new tuple won't go on the free_list:
/* Check for overflow */
if (nbytes / sizeof(PyObject *) != (size_t)size ||
(nbytes > PY_SSIZE_T_MAX - sizeof(PyTupleObject) - sizeof(PyObject *)))
{
return PyErr_NoMemory();
}
nbytes += sizeof(PyTupleObject) - sizeof(PyObject *);
nbytes is never used after the overflow check, so the last addition is a waste. |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2015年11月09日 05:44:35 | Jim Nasby | set | recipients:
+ Jim Nasby |
| 2015年11月09日 05:44:35 | Jim Nasby | set | messageid: <1447047875.1.0.253447135487.issue25587@psf.upfronthosting.co.za> |
| 2015年11月09日 05:44:34 | Jim Nasby | link | issue25587 messages |
| 2015年11月09日 05:44:34 | Jim Nasby | create |
|