Skip to content

Commit

Permalink
pid: ignore compiler-generated internal function names
Browse files Browse the repository at this point in the history
Signed-off-by: Kris Van Hees <kris.van.hees@oracle.com>
Reviewed-by: Eugene Loh <eugene.loh@oracle.com>
  • Loading branch information
kvanhees committed Sep 13, 2022
1 parent d08cc97 commit ea1a50c
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions libdtrace/dt_pid.c
Original file line number Diff line number Diff line change
Expand Up @@ -277,12 +277,14 @@ dt_pid_sym_filt(void *arg, const GElf_Sym *symp, const char *func)
if (strcmp(func, "_init") == 0 || strcmp(func, "_fini") == 0)
return 0;

/*
* Versioned identifiers are a problem.
*/
/* Versioned identifiers are a problem. */
if (strchr(func, '@') != NULL)
return 0;

/* Compiler-generated internal identifiers are a problem. */
if (strchr(func, '.') != NULL)
return 0;

if ((pp->dpp_last_taken = gmatch(func, pp->dpp_func)) != 0) {
pp->dpp_last = *symp;
return dt_pid_per_sym(pp, symp, func);
Expand Down

0 comments on commit ea1a50c

Please sign in to comment.