Message191806
Similar issue:
..\Objects\funcobject.c(636): warning C4244: 'function' : conversion from 'Py_ssize_t' to 'int', possible loss of data [C:\buildbot.python.org\3.x.kloth-win64\build\PCbuild\pythoncore.vcxproj]
..\Objects\funcobject.c(637): warning C4244: 'function' : conversion from 'Py_ssize_t' to 'int', possible loss of data [C:\buildbot.python.org\3.x.kloth-win64\build\PCbuild\pythoncore.vcxproj]
..\Objects\funcobject.c(637): warning C4244: 'function' : conversion from 'Py_ssize_t' to 'int', possible loss of data [C:\buildbot.python.org\3.x.kloth-win64\build\PCbuild\pythoncore.vcxproj]
Extract of function_call() function:
result = PyEval_EvalCodeEx(
PyFunction_GET_CODE(func),
PyFunction_GET_GLOBALS(func), (PyObject *)NULL,
&PyTuple_GET_ITEM(arg, 0), PyTuple_GET_SIZE(arg),
k, nk, d, nd,
PyFunction_GET_KW_DEFAULTS(func),
PyFunction_GET_CLOSURE(func));
argcount, kwcount and defcount are int, whereas function_call() pass Py_ssize_t values.
function_call() should check PyTuple_GET_SIZE(arg) <= INT_MAX, nk <= INT_MAX and nd <= INT_MAX. |
|
| Date |
User |
Action |
Args |
| 2013-06-24 21:23:21 | vstinner | set | recipients:
+ vstinner |
| 2013-06-24 21:23:21 | vstinner | set | messageid: <[email protected]> |
| 2013-06-24 21:23:21 | vstinner | link | issue18295 messages |
| 2013-06-24 21:23:21 | vstinner | create | |
|