From: Matthew Fernandez Date: Sun, 6 Sep 2020 17:28:40 +0000 (-0700) Subject: simplify xdot_begin_anchor with agxbprint X-Git-Tag: 2.46.0~20^2^2~77^2~4 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=cef501add3cf7a1d9258ade8157958651f8a18c5;p=graphviz simplify xdot_begin_anchor with agxbprint --- diff --git a/plugin/core/gvrender_core_dot.c b/plugin/core/gvrender_core_dot.c index 21638fce2..293823025 100644 --- a/plugin/core/gvrender_core_dot.c +++ b/plugin/core/gvrender_core_dot.c @@ -321,7 +321,6 @@ static void xdot_end_edge(GVJ_t* job) static void xdot_begin_anchor(GVJ_t * job, char *href, char *tooltip, char *target, char *id) { emit_state_t emit_state = job->obj->emit_state; - char buf[3]; /* very small integer */ unsigned int flags = 0; agxbput(xbufs[emit_state], "H "); @@ -331,8 +330,7 @@ static void xdot_begin_anchor(GVJ_t * job, char *href, char *tooltip, char *targ flags |= 2; if (target) flags |= 4; - sprintf (buf, "%d ", flags); - agxbput(xbufs[emit_state], buf); + agxbprint(xbufs[emit_state], "%d ", flags); if (href) xdot_str (job, "", href); if (tooltip)