aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'portage_with_autodep/pym/portage/util/_dyn_libs/LinkageMapELF.py')
-rw-r--r--portage_with_autodep/pym/portage/util/_dyn_libs/LinkageMapELF.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/portage_with_autodep/pym/portage/util/_dyn_libs/LinkageMapELF.py b/portage_with_autodep/pym/portage/util/_dyn_libs/LinkageMapELF.py
index 52670d9..e71ac73 100644
--- a/portage_with_autodep/pym/portage/util/_dyn_libs/LinkageMapELF.py
+++ b/portage_with_autodep/pym/portage/util/_dyn_libs/LinkageMapELF.py
@@ -267,6 +267,7 @@ class LinkageMapELF(object):
owner = plibs.pop(fields[1], None)
lines.append((owner, "scanelf", ";".join(fields)))
proc.wait()
+ proc.stdout.close()
if plibs:
# Preserved libraries that did not appear in the scanelf output.
@@ -286,6 +287,13 @@ class LinkageMapELF(object):
l = l.rstrip("\n")
if not l:
continue
+ if '\0' in l:
+ # os.stat() will raise "TypeError: must be encoded string
+ # without NULL bytes, not str" in this case.
+ writemsg_level(_("\nLine contains null byte(s) " \
+ "in %s: %s\n\n") % (location, l),
+ level=logging.ERROR, noiselevel=-1)
+ continue
fields = l.split(";")
if len(fields) < 5:
writemsg_level(_("\nWrong number of fields " \