Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
btf: take first entry on multiple function matches
TypeByName() can fail with ErrMultipleMatches if we have multiple candidates. If so, let's try again and take first match as it is. This can help solve our immediate issue of having multiple definitions per system calls, however the long-term fix would be to iterate over all candidate, match their proto and arguments definitions, then attach to the corresponding ones. Example output: time="2024-05-31T15:53:17+01:00" level=info msg="BTF includes '2' matched candidates on call \"__x64_sys_init_module\", using first one" metadata=/home/tixxdz/btf Signed-off-by: Djalal Harouni <[email protected]>
- Loading branch information