[Python-checkins] python/dist/src/Lib xmlrpclib.py,1.27,1.28

niemeyer@users.sourceforge.net niemeyer@users.sourceforge.net
Sun, 15 Jun 2003 19:49:44 -0700


Update of /cvsroot/python/python/dist/src/Lib
In directory sc8-pr-cvs1:/tmp/cvs-serv27917/Lib

Modified Files:
	xmlrpclib.py 
Log Message:
Made DateTime's constructor accept a time.struct_time class,
besides plain tuples.


Index: xmlrpclib.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/xmlrpclib.py,v
retrieving revision 1.27
retrieving revision 1.28
diff -C2 -d -r1.27 -r1.28
*** xmlrpclib.py	12 May 2003 20:19:36 -0000	1.27
--- xmlrpclib.py	16 Jun 2003 02:49:42 -0000	1.28
***************
*** 344,348 ****
      def __init__(self, value=0):
          if not isinstance(value, StringType):
!             if not isinstance(value, TupleType):
                  if value == 0:
                      value = time.time()
--- 344,348 ----
      def __init__(self, value=0):
          if not isinstance(value, StringType):
!             if not isinstance(value, (TupleType, time.struct_time)):
                  if value == 0:
                      value = time.time()