Skip to content

Commit e011fa3

Browse files
committed
Note the concurrent seek() trigger in the NEWS and comment
1 parent 4752da6 commit e011fa3

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
Fix a crash in the C implementation of :meth:`io.TextIOWrapper.tell` when the
2-
decoder's ``getstate`` method triggers a reentrant seek. Patch by tonghuaroot.
2+
decoder's ``getstate`` method triggers a reentrant seek, or when another thread
3+
seeks the same stream concurrently. Patch by tonghuaroot.

Modules/_io/textio.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2875,7 +2875,7 @@ _io_TextIOWrapper_tell_impl(textio *self)
28752875

28762876
assert (PyBytes_Check(next_input));
28772877

2878-
/* Own next_input: a reentrant seek in the decoder can drop self->snapshot. */
2878+
/* Own next_input: a reentrant or concurrent seek can drop the snapshot. */
28792879
Py_INCREF(next_input);
28802880

28812881
cookie.start_pos -= PyBytes_GET_SIZE(next_input);

0 commit comments

Comments
 (0)