[DTrace-devel] [PATCH 1/4] Fix memory leak of dt_error DIFO
Eugene Loh
eugene.loh at oracle.com
Wed Jun 9 18:56:52 PDT 2021
Reviewed-by: Eugene Loh <eugene.loh at oracle.com>
though to be honest I have absolutely no idea what's going on here. I
simply don't see that situation changing, though! Sure does not look
like a normal "memory leak."
On 6/8/21 11:37 PM, Kris Van Hees wrote:
> Signed-off-by: Kris Van Hees <kris.van.hees at oracle.com>
> ---
> libdtrace/dt_cc.c | 9 +++++++--
> 1 file changed, 7 insertions(+), 2 deletions(-)
>
> diff --git a/libdtrace/dt_cc.c b/libdtrace/dt_cc.c
> index 86b06237..413c1c22 100644
> --- a/libdtrace/dt_cc.c
> +++ b/libdtrace/dt_cc.c
> @@ -2141,10 +2141,15 @@ dt_construct(dtrace_hdl_t *dtp, dt_probe_t *prp, uint_t cflags, dt_ident_t *idp)
> dp = dt_as(yypcb);
>
> /*
> - * If we were called with an identifier, assign the DIFO to it.
> + * If we were called with an identifier, assign the DIFO to it. We
> + * also must ensure that the identifier is of the correct kind (and
> + * has the proper configuration) - we do this by morphing it into
> + * itself.
> */
> - if (idp != NULL)
> + if (idp != NULL) {
> + dt_ident_morph(idp, idp->di_kind, &dt_idops_difo, dtp);
> dt_ident_set_data(idp, dp);
> + }
>
> out:
> if (dtp->dt_cdefs_fd != -1 &&
More information about the DTrace-devel
mailing list