mirror of
https://github.com/python/cpython.git
synced 2026-06-04 16:50:51 +00:00
gh-149816: add missing critical section on self in buffered_iternext (#150295)
This commit is contained in:
parent
1b20d1933f
commit
e8545ed3ea
1 changed files with 2 additions and 0 deletions
|
|
@ -1509,7 +1509,9 @@ buffered_iternext(PyObject *op)
|
|||
tp == state->PyBufferedRandom_Type)
|
||||
{
|
||||
/* Skip method call overhead for speed */
|
||||
Py_BEGIN_CRITICAL_SECTION(self);
|
||||
line = _buffered_readline(self, -1);
|
||||
Py_END_CRITICAL_SECTION();
|
||||
}
|
||||
else {
|
||||
line = PyObject_CallMethodNoArgs((PyObject *)self,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue