Commit 8f53dcd
path_error() uses GetLastError() on Windows, but some os functions
are implemented via CRT APIs which report errors via errno.
This may result in raising OSError with invalid error code (such
as zero).
Introduce posix_path_error() function and use it where appropriate.
(cherry picked from commit 8346031)
Co-authored-by: Alexey Izbyshev <izbyshev@ispras.ru>
1 parent 3e5bcd1 commit 8f53dcd
3 files changed
Lines changed: 27 additions & 3 deletions
File tree
- Lib/test
- Misc/NEWS.d/next/Windows
- Modules
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1589 | 1589 | | |
1590 | 1590 | | |
1591 | 1591 | | |
| 1592 | + | |
| 1593 | + | |
| 1594 | + | |
| 1595 | + | |
| 1596 | + | |
| 1597 | + | |
| 1598 | + | |
| 1599 | + | |
| 1600 | + | |
| 1601 | + | |
1592 | 1602 | | |
1593 | 1603 | | |
1594 | 1604 | | |
| |||
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1421 | 1421 | | |
1422 | 1422 | | |
1423 | 1423 | | |
| 1424 | + | |
| 1425 | + | |
| 1426 | + | |
| 1427 | + | |
| 1428 | + | |
| 1429 | + | |
1424 | 1430 | | |
1425 | 1431 | | |
1426 | 1432 | | |
1427 | 1433 | | |
1428 | 1434 | | |
1429 | 1435 | | |
1430 | 1436 | | |
1431 | | - | |
| 1437 | + | |
1432 | 1438 | | |
1433 | 1439 | | |
1434 | 1440 | | |
| |||
1449 | 1455 | | |
1450 | 1456 | | |
1451 | 1457 | | |
| 1458 | + | |
| 1459 | + | |
| 1460 | + | |
| 1461 | + | |
| 1462 | + | |
| 1463 | + | |
1452 | 1464 | | |
1453 | 1465 | | |
1454 | 1466 | | |
| |||
5097 | 5109 | | |
5098 | 5110 | | |
5099 | 5111 | | |
5100 | | - | |
| 5112 | + | |
5101 | 5113 | | |
5102 | 5114 | | |
5103 | 5115 | | |
| |||
9060 | 9072 | | |
9061 | 9073 | | |
9062 | 9074 | | |
9063 | | - | |
| 9075 | + | |
9064 | 9076 | | |
9065 | 9077 | | |
9066 | 9078 | | |
| |||
0 commit comments