Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 557a044

Browse files
committed
Fix the parent of WindowsError - both the comments in this source file, and the previous exceptions.py have WindowsError as a sub-class of OSError.
1 parent 041307d commit 557a044

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Python/exceptions.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -883,7 +883,7 @@ static struct {
883883
{"IOError", &PyExc_IOError, &PyExc_EnvironmentError, IOError__doc__},
884884
{"OSError", &PyExc_OSError, &PyExc_EnvironmentError, OSError__doc__},
885885
#ifdef MS_WINDOWS
886-
{"WindowsError", &PyExc_WindowsError, &PyExc_EnvironmentError,
886+
{"WindowsError", &PyExc_WindowsError, &PyExc_OSError,
887887
WindowsError__doc__},
888888
#endif /* MS_WINDOWS */
889889
{"EOFError", &PyExc_EOFError, 0, EOFError__doc__},

0 commit comments

Comments
 (0)