]> granicus.if.org Git - python/commitdiff
#14984: only import pwd on POSIX.
authorR David Murray <rdmurray@bitdance.com>
Wed, 18 Sep 2013 12:49:25 +0000 (08:49 -0400)
committerR David Murray <rdmurray@bitdance.com>
Wed, 18 Sep 2013 12:49:25 +0000 (08:49 -0400)
Lib/netrc.py

index 2b45bc2518abaa3030d59b8032ccdf42ddb73830..ce6f4ddb9764e4853af34ac61e7807ed5cf33438 100644 (file)
@@ -2,7 +2,9 @@
 
 # Module and documentation by Eric S. Raymond, 21 Dec 1998
 
-import os, stat, shlex, pwd
+import os, stat, shlex
+if os.name == 'posix':
+    import pwd
 
 __all__ = ["netrc", "NetrcParseError"]