]> granicus.if.org Git - python/commitdiff
Before comparing os.uname() to BeOS check that os.uname actually exists:-)
authorJack Jansen <jack.jansen@cwi.nl>
Fri, 15 Sep 2000 12:59:46 +0000 (12:59 +0000)
committerJack Jansen <jack.jansen@cwi.nl>
Fri, 15 Sep 2000 12:59:46 +0000 (12:59 +0000)
Lib/socket.py

index e5180b5611c7dd053e9c7cfef86f918dfc83155c..b28de1d39cad92d463f815b660ea1f89dacd0def 100644 (file)
@@ -42,7 +42,7 @@ from _socket import *
 import os, sys
 
 if (sys.platform.lower().startswith("win")
-    or os.uname()[0] == "BeOS"):
+    or (hasattr(os, 'uname') and os.uname()[0] == "BeOS")):
 
     # be sure this happens only once, even in the face of reload():
     try: