Commit d601c0a5 authored by Luca Canali's avatar Luca Canali

Fix for find_symbol method, issue #478

parent 5cb8de7a
...@@ -464,7 +464,7 @@ class BPF(object): ...@@ -464,7 +464,7 @@ class BPF(object):
return symbols[sym] return symbols[sym]
with os.popen("""/usr/bin/objdump -tT %s | \ with os.popen("""/usr/bin/objdump -tT %s | \
awk -v sym=%s '$NF == sym && $4 == ".text" \ awk -v sym=%s '$NF == sym && ($4 == ".text" || $4 == "text.hot" || $4 == "text.unlikely") \
{ print $1; exit }'""" % (path, sym)) as f: { print $1; exit }'""" % (path, sym)) as f:
data = f.read().rstrip() data = f.read().rstrip()
if not data: if not data:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment