Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork33.7k
Closed
Description
Bug report
Bug description:
This is probably not an issue but here are the known "temporary" overflows:
// format = 'K'returnPyLong_FromUnsignedLongLong((long long)va_arg(*p_va,unsignedlong long));
Note thatva_arg(*p_va, unsigned long long) will be converted into an unsigned long long, and then into a long long, and then back to an unsigned long long. So if we were to have an overflow here, it shouldn't really matter. Indeed, takev = (1ULL << 63) + 2. We have:
unsigned long longv2=va_arg(*p_va,unsignedlong long);// v2 = 9223372036854775810long longv3= (long long)v2;// v3 = -9223372036854775806PyObject*v4=PyLong_FromUnsignedLongLong(v3);// v4 = 9223372036854775810 as PyObject as v3 was casted back to an unsigned long long
CPython versions tested on:
CPython main branch
Operating systems tested on:
No response