Commit 158db11
committed
Fix realpath ValueError on null byte
Calling os.path.realpath with a path containg a null byte ("\x00")
it raised an ValueError on posix systems.
This fix will catch the ValueError similar to how other path operations are handling such an Error.
e.g. os.path.exists, os.path.ismount, os.fspath, os.path.islink1 parent 6150bb2 commit 158db11
2 files changed
+10
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
460 | 460 | | |
461 | 461 | | |
462 | 462 | | |
463 | | - | |
| 463 | + | |
464 | 464 | | |
465 | 465 | | |
466 | 466 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
646 | 646 | | |
647 | 647 | | |
648 | 648 | | |
| 649 | + | |
| 650 | + | |
| 651 | + | |
| 652 | + | |
| 653 | + | |
| 654 | + | |
| 655 | + | |
| 656 | + | |
| 657 | + | |
649 | 658 | | |
650 | 659 | | |
651 | 660 | | |
| |||
0 commit comments