[DTrace-devel] [PATCH v2] Add support for inet_ntop() subroutine
Eugene Loh
eugene.loh at oracle.com
Thu Sep 14 22:44:30 UTC 2023
Reviewed-by: Eugene Loh <eugene.loh at oracle.com>
I confess I don't really understand this stuff but oh well.
Also, test/unittest/funcs/tst.inet_ntop.d fails. Should the .r file be
changed so that the AF_INET6 cases with embedded IPV4 no longer have
IPv6 prefixes?
And...
On 9/14/23 15:56, Eugene Loh via DTrace-devel wrote:
> diff --git a/libdtrace/dt_cg.c b/libdtrace/dt_cg.c
> +static void
> +dt_cg_subr_inet_ntop(dt_node_t *dnp, dt_irlist_t *dlp, dt_regset_t *drp)
> +{
> + dt_node_t *af = dnp->dn_args;
> + dt_node_t *addr = af->dn_list;
> + dt_node_t *tnp, *cnp, *lnp, *rnp, *anp, *xnp;;
s/;;/;/
> [...]
> + xnp = dt_node_type(ddp); /* frees ddp */
> + /* Create a node to represent: (type)addr */
> + xnp = dt_node_op2(DT_TOK_LPAR, xnp, addr);
> [...]
> + xnp = dt_node_type(ddp); /* frees ddp */
> +
> + xnp = dt_node_op2(DT_TOK_LPAR, xnp, addr); /* (type)addr */
Might as well make those two sections of code as boringly similar as
possible, comments and all.
More information about the DTrace-devel
mailing list