* mdocml: Remove the variable sz because it's invariantly == 0, along with
@ 2013-05-18 17:08 schwarze
0 siblings, 0 replies; only message in thread
From: schwarze @ 2013-05-18 17:08 UTC (permalink / raw)
To: source
Log Message:
-----------
Remove the variable sz because it's invariantly == 0,
along with the dead code testing whether it's positive.
Reported by Ulrich Spoerlein <uqs@spoerlein.net>,
found by Coverity Scan CID 975717.
While here, remove the now unused **params array as well,
which Coverity apparently missed, at least it wasn't reported...
Modified Files:
--------------
mdocml:
tree.c
Revision Data
-------------
Index: tree.c
===================================================================
RCS file: /usr/vhosts/mdocml.bsd.lv/cvs/mdocml/tree.c,v
retrieving revision 1.47
retrieving revision 1.48
diff -Ltree.c -Ltree.c -u -p -r1.47 -r1.48
--- tree.c
+++ tree.c
@@ -58,13 +58,11 @@ print_mdoc(const struct mdoc_node *n, in
{
const char *p, *t;
int i, j;
- size_t argc, sz;
- char **params;
+ size_t argc;
struct mdoc_argv *argv;
argv = NULL;
- argc = sz = 0;
- params = NULL;
+ argc = 0;
t = p = NULL;
switch (n->type) {
@@ -162,9 +160,6 @@ print_mdoc(const struct mdoc_node *n, in
printf(" ]");
}
- for (i = 0; i < (int)sz; i++)
- printf(" [%s]", params[i]);
-
printf(" %d:%d\n", n->line, n->pos);
}
--
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-05-18 17:08 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-05-18 17:08 mdocml: Remove the variable sz because it's invariantly == 0, along with 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).