mirror of
https://github.com/python/cpython.git
synced 2025-11-01 18:51:43 +00:00
GH-90699: fix ref counting of static immortal strings (gh-94850)
This commit is contained in:
parent
88e4eeba25
commit
1834133e66
3 changed files with 4 additions and 2 deletions
|
|
@ -2244,7 +2244,7 @@ _textiowrapper_readline(textio *self, Py_ssize_t limit)
|
|||
Py_CLEAR(chunks);
|
||||
}
|
||||
if (line == NULL) {
|
||||
line = &_Py_STR(empty);
|
||||
line = Py_NewRef(&_Py_STR(empty));
|
||||
}
|
||||
|
||||
return line;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue