summaryrefslogtreecommitdiff
path: root/python2.7/patches/linecache.diff
diff options
context:
space:
mode:
authorIgor Pashev <igor.pashev@nexenta.com>2013-04-10 11:42:21 +0400
committerIgor Pashev <igor.pashev@nexenta.com>2013-04-10 11:42:21 +0400
commit3fd7c70391fef9a1593b25a808766c352239e958 (patch)
tree8ed845aca8afc7bf489028a31db0fdf5ad6ce680 /python2.7/patches/linecache.diff
parent92b26142a3d204fb1ce30f68ba1dfdd7f92a0b36 (diff)
downloadcibs-pkgs-3fd7c70391fef9a1593b25a808766c352239e958.tar.gz
Adapt Debian patches
Diffstat (limited to 'python2.7/patches/linecache.diff')
-rw-r--r--python2.7/patches/linecache.diff16
1 files changed, 16 insertions, 0 deletions
diff --git a/python2.7/patches/linecache.diff b/python2.7/patches/linecache.diff
new file mode 100644
index 0000000..a7fdd5a
--- /dev/null
+++ b/python2.7/patches/linecache.diff
@@ -0,0 +1,16 @@
+# DP: Proper handling of packages in linecache.py
+
+--- a/Lib/linecache.py
++++ b/Lib/linecache.py
+@@ -108,6 +108,11 @@
+ if os.path.isabs(filename):
+ return []
+
++ # Take care to handle packages
++ if basename == '__init__.py':
++ # filename referes to a package
++ basename = filename
++
+ for dirname in sys.path:
+ # When using imputil, sys.path may contain things other than
+ # strings; ignore them when it happens.