From: Jack Jansen Date: Fri, 15 Sep 2000 12:59:46 +0000 (+0000) Subject: Before comparing os.uname() to BeOS check that os.uname actually exists:-) X-Git-Tag: v2.0b2~293 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=344ecdb249c9e25010084fdecc21c17d2c725b82;p=thirdparty%2FPython%2Fcpython.git Before comparing os.uname() to BeOS check that os.uname actually exists:-) --- diff --git a/Lib/socket.py b/Lib/socket.py index e5180b5611c7..b28de1d39cad 100644 --- a/Lib/socket.py +++ b/Lib/socket.py @@ -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: