[Zope-Checkins] CVS: Packages/ZServer - __init__.py:1.22

Fred L. Drake, Jr. fdrake@acm.org
Fri, 22 Feb 2002 11:17:16 -0500


Update of /cvs-repository/Packages/ZServer
In directory cvs.zope.org:/tmp/cvs-serv5840

Modified Files:
	__init__.py 
Log Message:
Do not import FCNTL unless we actually have to, avoiding a warning from
Python 2.2.


=== Packages/ZServer/__init__.py 1.21 => 1.22 ===
 # to make this work, as a 2.2-ism crept into the asyncore code.
 if os.name == 'posix':
-    import fcntl, FCNTL
+    import fcntl
     if not hasattr(fcntl, 'F_GETFL'):
+        import FCNTL
         fcntl.F_GETFL = FCNTL.F_GETFL
         fcntl.F_SETFL = FCNTL.F_SETFL
-    
+
 from medusa import asyncore
 sys.modules['asyncore'] = asyncore