mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
bpo-9566: Fix size_t=>int downcast warnings (#5230)
* Use wider types (int => Py_ssize_t) to avoid integer overflows. * Fix gc.get_freeze_count(): use Py_ssize_t type rather than int, since gc_list_size() returns a Py_ssize_t.
This commit is contained in:
parent
ab74504346
commit
05d68a8bd8
5 changed files with 14 additions and 14 deletions
|
@ -52,9 +52,9 @@ _Py_IDENTIFIER(stderr);
|
|||
#include "clinic/bltinmodule.c.h"
|
||||
|
||||
static PyObject*
|
||||
update_bases(PyObject *bases, PyObject *const *args, int nargs)
|
||||
update_bases(PyObject *bases, PyObject *const *args, Py_ssize_t nargs)
|
||||
{
|
||||
int i, j;
|
||||
Py_ssize_t i, j;
|
||||
PyObject *base, *meth, *new_base, *result, *new_bases = NULL;
|
||||
PyObject *stack[1] = {bases};
|
||||
assert(PyTuple_Check(bases));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue