]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
[3.11] gh-107913: Fix possible losses of OSError error codes (GH-107930) (GH-108524)
authorSerhiy Storchaka <storchaka@gmail.com>
Sun, 27 Aug 2023 12:18:58 +0000 (15:18 +0300)
committerGitHub <noreply@github.com>
Sun, 27 Aug 2023 12:18:58 +0000 (12:18 +0000)
commitb9fc5363997c0cbb78a8d654f9bf6cac1fc056df
treef63833fb348e102e5eb9ab296cd7acbeca861879
parent8a275f7c0120c6ebd1cabe2ddba38c2c6a33c958
[3.11] gh-107913: Fix possible losses of OSError error codes (GH-107930) (GH-108524)

Functions like PyErr_SetFromErrno() and SetFromWindowsErr() should be
called immediately after using the C API which sets errno or the Windows
error code.
(cherry picked from commit 2b15536fa94d07e9e286826c23507402313ec7f4)
17 files changed:
Misc/NEWS.d/next/Library/2023-08-14-11-18-13.gh-issue-107913.4ooY6i.rst [new file with mode: 0644]
Modules/_cursesmodule.c
Modules/_io/fileio.c
Modules/_io/winconsoleio.c
Modules/_localemodule.c
Modules/_multiprocessing/semaphore.c
Modules/_ssl.c
Modules/faulthandler.c
Modules/fcntlmodule.c
Modules/getpath.c
Modules/mmapmodule.c
Modules/overlapped.c
Modules/posixmodule.c
Modules/selectmodule.c
Modules/socketmodule.c
Objects/unicodeobject.c
Python/fileutils.c