* mdocml: The return value from parse_man() is completely unused, so make
@ 2013-06-05 21:21 schwarze
0 siblings, 0 replies; only message in thread
From: schwarze @ 2013-06-05 21:21 UTC (permalink / raw)
To: source
Log Message:
-----------
The return value from parse_man() is completely unused,
so make the function void; no functional change.
Modified Files:
--------------
mdocml:
mandocdb.c
Revision Data
-------------
Index: mandocdb.c
===================================================================
RCS file: /usr/vhosts/mdocml.bsd.lv/cvs/mdocml/mandocdb.c,v
retrieving revision 1.60
retrieving revision 1.61
diff -Lmandocdb.c -Lmandocdb.c -u -p -r1.60 -r1.61
--- mandocdb.c
+++ mandocdb.c
@@ -140,8 +140,7 @@ static void ofadd(int, const char *, co
static void offree(void);
static void ofmerge(struct mchars *, struct mparse *);
static void parse_catpage(struct of *);
-static int parse_man(struct of *,
- const struct man_node *);
+static void parse_man(struct of *, const struct man_node *);
static void parse_mdoc(struct of *, const struct mdoc_node *);
static int parse_mdoc_body(struct of *, const struct mdoc_node *);
static int parse_mdoc_head(struct of *, const struct mdoc_node *);
@@ -1181,7 +1180,7 @@ putmdockey(const struct of *of, const st
}
}
-static int
+static void
parse_man(struct of *of, const struct man_node *n)
{
const struct man_node *head, *body;
@@ -1190,7 +1189,7 @@ parse_man(struct of *of, const struct ma
size_t sz, titlesz;
if (NULL == n)
- return(0);
+ return;
/*
* We're only searching for one thing: the first text child in
@@ -1232,7 +1231,7 @@ parse_man(struct of *of, const struct ma
title[titlesz - 1] = ' ';
}
if (NULL == title)
- return(1);
+ return;
title = mandoc_realloc(title, titlesz + 1);
title[titlesz] = '\0';
@@ -1245,7 +1244,7 @@ parse_man(struct of *of, const struct ma
if (0 == (sz = strlen(sv))) {
free(title);
- return(1);
+ return;
}
/* Erase trailing space. */
@@ -1256,7 +1255,7 @@ parse_man(struct of *of, const struct ma
if (start == sv) {
free(title);
- return(1);
+ return;
}
start = sv;
@@ -1293,7 +1292,7 @@ parse_man(struct of *of, const struct ma
if (sv == start) {
putkey(of, start, TYPE_Nm);
free(title);
- return(1);
+ return;
}
while (isspace((unsigned char)*start))
@@ -1317,15 +1316,12 @@ parse_man(struct of *of, const struct ma
of->desc = stradd(start);
putkey(of, start, TYPE_Nd);
free(title);
- return(1);
+ return;
}
}
for (n = n->child; n; n = n->next)
- if (parse_man(of, n))
- return(1);
-
- return(0);
+ parse_man(of, n);
}
static void
--
To unsubscribe send an email to source+unsubscribe@mdocml.bsd.lv
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2013-06-05 21:21 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-06-05 21:21 mdocml: The return value from parse_man() is completely unused, so make schwarze
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).