summaryrefslogtreecommitdiffstatshomepage
path: root/mdoc_macro.c
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2009-07-25 16:03:03 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2009-07-25 16:03:03 +0000
commit4690a796b3a9cd2ed9769323c29d5e442d4be21f (patch)
treeb1b4f7e79c008f6af9c8283d26cd23ad27528079 /mdoc_macro.c
parent1dc71205dae2e5dd56cf1f23033d63c7e14a0795 (diff)
downloadmandoc-4690a796b3a9cd2ed9769323c29d5e442d4be21f.tar.gz
mandoc-4690a796b3a9cd2ed9769323c29d5e442d4be21f.tar.zst
mandoc-4690a796b3a9cd2ed9769323c29d5e442d4be21f.zip
Patches and results of LLVM static analysis (thanks uqs@sporlein.net).
Diffstat (limited to 'mdoc_macro.c')
-rw-r--r--mdoc_macro.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/mdoc_macro.c b/mdoc_macro.c
index b156f0bd..97b157be 100644
--- a/mdoc_macro.c
+++ b/mdoc_macro.c
@@ -1,4 +1,4 @@
-/* $Id: mdoc_macro.c,v 1.26 2009/07/24 12:17:25 kristaps Exp $ */
+/* $Id: mdoc_macro.c,v 1.27 2009/07/25 16:03:03 kristaps Exp $ */
/*
* Copyright (c) 2008, 2009 Kristaps Dzonsons <kristaps@kth.se>
*
@@ -681,7 +681,7 @@ blk_exp_close(MACRO_PROT_ARGS)
mdoc->next = MDOC_NEXT_CHILD;
}
- for (lastarg = ppos, flushed = j = 0; ; j++) {
+ for (flushed = j = 0; ; j++) {
lastarg = *pos;
if (j == maxargs && ! flushed) {
@@ -760,7 +760,7 @@ in_line(MACRO_PROT_ARGS)
break;
}
- for (la = ppos, arg = NULL;; ) {
+ for (arg = NULL;; ) {
la = *pos;
c = mdoc_argv(mdoc, line, tok, &arg, pos, buf);
@@ -1046,7 +1046,7 @@ blk_part_imp(MACRO_PROT_ARGS)
/* XXX - no known argument macros. */
- for (lastarg = ppos;; ) {
+ for (;;) {
lastarg = *pos;
c = mdoc_args(mdoc, line, pos, buf, tok, &p);
assert(ARGS_PHRASE != c);
@@ -1107,7 +1107,6 @@ blk_part_exp(MACRO_PROT_ARGS)
int lastarg, flushed, j, c, maxargs;
char *p;
- lastarg = ppos;
flushed = 0;
/*
@@ -1243,7 +1242,7 @@ in_line_argn(MACRO_PROT_ARGS)
break;
}
- for (lastarg = ppos, arg = NULL;; ) {
+ for (arg = NULL;; ) {
lastarg = *pos;
c = mdoc_argv(mdoc, line, tok, &arg, pos, buf);