[Python-checkins] python/dist/src/Lib/hotshot log.py,1.9,1.10

fdrake@users.sourceforge.net fdrake@users.sourceforge.net
Thu, 18 Jul 2002 12:20:25 -0700


Update of /cvsroot/python/python/dist/src/Lib/hotshot
In directory usw-pr-cvs1:/tmp/cvs-serv1692

Modified Files:
	log.py 
Log Message:
Simplify; the low-level log reader is now always a modern iterator,
and should never return None.  (It only did this for an old version of
HotShot that was trying to still work with a patched Python 2.1.)


Index: log.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/hotshot/log.py,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** log.py	18 Jul 2002 19:17:20 -0000	1.9
--- log.py	18 Jul 2002 19:20:23 -0000	1.10
***************
*** 96,105 ****
      def next(self, index=0):
          while 1:
!             try:
!                 what, tdelta, fileno, lineno = self._nextitem()
!             except TypeError:
!                 # logreader().next() returns None at the end
!                 self._reader.close()
!                 raise StopIteration()
  
              # handle the most common cases first
--- 96,100 ----
      def next(self, index=0):
          while 1:
!             what, tdelta, fileno, lineno = self._nextitem()
  
              # handle the most common cases first