]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-111942: Fix crashes in TextIOWrapper.reconfigure() (GH-111976)
authorSerhiy Storchaka <storchaka@gmail.com>
Tue, 14 Nov 2023 15:37:56 +0000 (17:37 +0200)
committerGitHub <noreply@github.com>
Tue, 14 Nov 2023 15:37:56 +0000 (17:37 +0200)
commitee06fffd38cb51ce1c045da9d8336d9ce13c318a
tree764d92fd0d9f750b2973004c2e7f46c91299adbf
parenta519b87958da0b340caef48349d6e3c23c98e47e
gh-111942: Fix crashes in TextIOWrapper.reconfigure() (GH-111976)

* Fix crash when encoding is not string or None.
* Fix crash when both line_buffering and write_through raise exception
  when converted ti int.
* Add a number of tests for constructor and reconfigure() method
  with invalid arguments.
Lib/test/test_io.py
Misc/NEWS.d/next/Library/2023-11-10-22-08-28.gh-issue-111942.MDFm6v.rst [new file with mode: 0644]
Modules/_io/textio.c