[Zope-Checkins] CVS: Zope/lib/python/ZServer - FTPServer.py:1.27

Fred L. Drake, Jr. fred@zope.com
Wed, 9 Jul 2003 12:26:02 -0400


Update of /cvs-repository/Zope/lib/python/ZServer
In directory cvs.zope.org:/tmp/cvs-serv12488/ZServer

Modified Files:
	FTPServer.py 
Log Message:
Replace apply(f,args,kw) with f(*args,**kw) to avoid deprecation warnings
from Python 2.3.
These warnings are displayed when running the unit tests.
This patch fixes the occurrances that are triggered by the unit tests;
there are probably others.


=== Zope/lib/python/ZServer/FTPServer.py 1.26 => 1.27 ===
--- Zope/lib/python/ZServer/FTPServer.py:1.26	Tue Mar 18 16:15:14 2003
+++ Zope/lib/python/ZServer/FTPServer.py	Wed Jul  9 12:25:26 2003
@@ -98,7 +98,7 @@
         self.cookies={}
 
     def _join_paths(self,*args):
-        path=apply(os.path.join,args)
+        path=os.path.join(*args)
         path=os.path.normpath(path)
         if os.sep != '/':
             path=path.replace(os.sep,'/')
@@ -543,7 +543,7 @@
         c=self.callback
         self.callback=None
         self.args=None
-        apply(c,args)
+        c(*args)
 
 
 class FTPLimiter:
@@ -599,7 +599,7 @@
 
     def __init__(self,module,*args,**kw):
         self.shutup=1
-        apply(ftp_server.__init__, (self, None) + args, kw)
+        ftp_server.__init__(self, None, *args, **kw)
         self.shutup=0
         self.module=module
         self.log_info('FTP server started at %s\n'