From 59c462368ef46b648cd8bd578930ea28a5aa8681 Mon Sep 17 00:00:00 2001 From: Matthew Fernandez Date: Sun, 21 Nov 2021 15:20:20 -0800 Subject: [PATCH] htmlenv_t.objid_set: use a C99 bool instead of boolean --- lib/common/htmltable.c | 5 +++-- lib/common/htmltable.h | 4 +++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/lib/common/htmltable.c b/lib/common/htmltable.c index 7f0a2f3b1..fe78701dc 100644 --- a/lib/common/htmltable.c +++ b/lib/common/htmltable.c @@ -37,6 +37,7 @@ #include #include #include +#include #define DEFAULT_BORDER 1 #define DEFAULT_CELLPADDING 2 @@ -389,7 +390,7 @@ initAnchor(GVJ_t * job, htmlenv_t * env, htmldata_t * data, boxf b, agxbinit(&xb, SMALLBUF, buf); if (!env->objid) { env->objid = strdup(getObjId(job, obj->u.n, &xb)); - env->objid_set = 1; + env->objid_set = true; } agxbprint(&xb, "%s_%d", env->objid, anchorId++); id = agxbuse(&xb); @@ -765,7 +766,7 @@ void emit_html_label(GVJ_t * job, htmllabel_t * lp, textlabel_t * tp) env.finfo.size = tp->fontsize; env.imgscale = agget(job->obj->u.n, "imagescale"); env.objid = job->obj->id; - env.objid_set = 0; + env.objid_set = false; if ((env.imgscale == NULL) || (env.imgscale[0] == '\0')) env.imgscale = "false"; if (lp->kind == HTML_TBL) { diff --git a/lib/common/htmltable.h b/lib/common/htmltable.h index 6c652a31d..d8e387df0 100644 --- a/lib/common/htmltable.h +++ b/lib/common/htmltable.h @@ -10,6 +10,8 @@ #pragma once +#include + #ifdef __cplusplus extern "C" { #endif @@ -156,7 +158,7 @@ extern "C" { graph_t *g; char *imgscale; char *objid; - boolean objid_set; + bool objid_set; } htmlenv_t; extern htmllabel_t *parseHTML(char *, int *, htmlenv_t *); -- 2.40.0