]> granicus.if.org Git - python/commitdiff
Change the sense of a test in how the profiler interprets exception events.
authorFred Drake <fdrake@acm.org>
Thu, 27 Sep 2001 16:28:42 +0000 (16:28 +0000)
committerFred Drake <fdrake@acm.org>
Thu, 27 Sep 2001 16:28:42 +0000 (16:28 +0000)
This should fix a bug in how time is allocated during exception propogation
(esp. in the presence of finally clauses).

Lib/profile.py

index b92bd91882539ff6d0265ae6218e9cc05fad4d5d..b58af1ea800611441e418e1667ad3fd30337abf8 100755 (executable)
@@ -241,7 +241,7 @@ class Profile:
 
     def trace_dispatch_exception(self, frame, t):
         rt, rtt, rct, rfn, rframe, rcur = self.cur
-        if (not rframe is frame) and rcur:
+        if (rframe is frame) and rcur:
             return self.trace_dispatch_return(rframe, t)
         return 0