Repository navigation
Commit 20ffdf7
On FreeBSD, use /dev/fd/ in fd_count() if it's mounted (GH-160210)
fd_count() can now use /dev/fd/ fdescfs file system if it's mounted,
which is not the case by default. Otherwise, call os.dup(fd) in a
loop which is slow since os.sysconf("SC_OPEN_MAX") is larger than
200,000 by default.
(cherry picked from commit 226ca06)
Co-authored-by: Victor Stinner <vstinner@python.org>
1 parent 260ee94 commit 20ffdf7
1 file changed
Lines changed: 21 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
685 | 685 | | |
686 | 686 | | |
687 | 687 | | |
| 688 | + | |
| 689 | + | |
| 690 | + | |
| 691 | + | |
| 692 | + | |
| 693 | + | |
| 694 | + | |
| 695 | + | |
| 696 | + | |
| 697 | + | |
| 698 | + | |
| 699 | + | |
| 700 | + | |
| 701 | + | |
| 702 | + | |
| 703 | + | |
| 704 | + | |
| 705 | + | |
688 | 706 | | |
689 | 707 | | |
690 | 708 | | |
| |||
732 | 750 | | |
733 | 751 | | |
734 | 752 | | |
| 753 | + | |
| 754 | + | |
| 755 | + | |
735 | 756 | | |
736 | 757 | | |
737 | 758 | | |
| |||
0 commit comments