10000 Merge #14984: only import pwd on POSIX. · python/cpython@58bf8d2 · GitHub
[go: up one dir, main page]

Skip to content

Commit 58bf8d2

Browse files
committed
Merge #14984: only import pwd on POSIX.
2 parents 8270a2c + 505be21 commit 58bf8d2

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Lib/netrc.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@
22

33
# Module and documentation by Eric S. Raymond, 21 Dec 1998
44

5-
import io, os, shlex, stat, pwd
5+
import os, shlex, stat
6+
if os.name == 'posix':
7+
import pwd
68

79
__all__ = ["netrc", "NetrcParseError"]
810

0 commit comments

Comments
 (0)
0