From 3d0b2ae345dda7699082d43836f6720493276292 Mon Sep 17 00:00:00 2001 From: Matthew Fernandez Date: Sat, 3 Jul 2021 09:50:06 -0700 Subject: [PATCH] remove unnecessary casts of parameters to agraphof The argument to agraphof is a void*, to which other pointers implicitly coerce. --- lib/common/htmltable.c | 2 +- lib/common/labels.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/common/htmltable.c b/lib/common/htmltable.c index 2377f2629..9eddd4871 100644 --- a/lib/common/htmltable.c +++ b/lib/common/htmltable.c @@ -2064,7 +2064,7 @@ int make_html_label(void *obj, textlabel_t * lp) env.g = ((Agraph_t *) obj)->root; break; case AGNODE: - env.g = agraphof(((Agnode_t *) obj)); + env.g = agraphof(obj); break; case AGEDGE: env.g = agraphof(aghead(((Agedge_t *) obj))); diff --git a/lib/common/labels.c b/lib/common/labels.c index d9ea71c86..75efd40ad 100644 --- a/lib/common/labels.c +++ b/lib/common/labels.c @@ -306,7 +306,7 @@ static char *strdup_and_subst_obj0 (char *str, void *obj, int escBackslash) } break; case AGNODE: - g_str = agnameof(agraphof((node_t *)obj)); + g_str = agnameof(agraphof(obj)); n_str = agnameof((node_t *)obj); tl = ND_label((node_t *)obj); if (tl) { -- 2.40.0