mirror of
https://github.com/python/cpython.git
synced 2025-11-01 02:38:53 +00:00
Issue #26200: Added Py_SETREF and replaced Py_XSETREF with Py_SETREF
in places where Py_DECREF was used.
This commit is contained in:
parent
e0805cf10e
commit
57a01d3a0e
20 changed files with 52 additions and 42 deletions
|
|
@ -668,7 +668,7 @@ save_unconsumed_input(compobject *self, int err)
|
|||
PyBytes_AS_STRING(self->unused_data), old_size);
|
||||
Py_MEMCPY(PyBytes_AS_STRING(new_data) + old_size,
|
||||
self->zst.next_in, self->zst.avail_in);
|
||||
Py_XSETREF(self->unused_data, new_data);
|
||||
Py_SETREF(self->unused_data, new_data);
|
||||
self->zst.avail_in = 0;
|
||||
}
|
||||
}
|
||||
|
|
@ -680,7 +680,7 @@ save_unconsumed_input(compobject *self, int err)
|
|||
(char *)self->zst.next_in, self->zst.avail_in);
|
||||
if (new_data == NULL)
|
||||
return -1;
|
||||
Py_XSETREF(self->unconsumed_tail, new_data);
|
||||
Py_SETREF(self->unconsumed_tail, new_data);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue