diff Lib/bdb.py @ 50162:4264cf00a75c 2.6

Merged revisions 67750-67751 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r67750 | nick.coghlan | 2008-12-14 20:54:50 +1000 (Sun, 14 Dec 2008) | 1 line Fix several issues relating to access to source code inside zipfiles. Initial work by Alexander Belopolsky. See Misc/NEWS in this checkin for details. ........ r67751 | nick.coghlan | 2008-12-14 21:09:40 +1000 (Sun, 14 Dec 2008) | 1 line Add file that was missed from r67750 ........
author Nick Coghlan <ncoghlan@gmail.com>
date Sun, 14 Dec 2008 11:30:16 +0000
parents c6c32842e71d
children 5fd09e410d36 c49bc330327c
line wrap: on
line diff
--- a/Lib/bdb.py	Fri Dec 12 21:25:13 2008 +0000
+++ b/Lib/bdb.py	Sun Dec 14 11:30:16 2008 +0000
@@ -347,7 +347,7 @@
             rv = frame.f_locals['__return__']
             s = s + '->'
             s = s + repr.repr(rv)
-        line = linecache.getline(filename, lineno)
+        line = linecache.getline(filename, lineno, frame.f_globals)
         if line: s = s + lprefix + line.strip()
         return s
 
@@ -589,7 +589,7 @@
         name = frame.f_code.co_name
         if not name: name = '???'
         fn = self.canonic(frame.f_code.co_filename)
-        line = linecache.getline(fn, frame.f_lineno)
+        line = linecache.getline(fn, frame.f_lineno, frame.f_globals)
         print '+++', fn, frame.f_lineno, name, ':', line.strip()
     def user_return(self, frame, retval):
         print '+++ return', retval