Skip to content

Commit

Permalink
Fix "'ArgString' object has no attribute 'rfind'" error
Browse files Browse the repository at this point in the history
os.path.dirname expects a string.
  • Loading branch information
pchaigno committed May 4, 2018
1 parent 01c843e commit d1a83c1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/python/bcc/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ def _find_file(filename):
if filename:
if not os.path.isfile(filename):
argv0 = ArgString(sys.argv[0])
t = b"/".join([os.path.abspath(os.path.dirname(argv0)), filename])
t = b"/".join([os.path.abspath(os.path.dirname(argv0.__str__())), filename])
if os.path.isfile(t):
filename = t
else:
Expand Down

0 comments on commit d1a83c1

Please sign in to comment.