summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2013-12-31 23:23:10 +0000
committerIngo Schwarze <schwarze@openbsd.org>2013-12-31 23:23:10 +0000
commit8165032a586fb8d32ff25ec7340db91a5568e604 (patch)
tree12fb3a063e97fce5041017ce1e096a75ccc6dc11
parent00a83eb67618ef2d3d4efc692882efa3dc6252ca (diff)
downloadmandoc-8165032a586fb8d32ff25ec7340db91a5568e604.tar.gz
Simplify: Remove an unused argument from the mandoc_eos() function.
No functional change.
-rw-r--r--libmandoc.h2
-rw-r--r--man.c2
-rw-r--r--man_macro.c2
-rw-r--r--mandoc.c8
-rw-r--r--mdoc.c2
-rw-r--r--mdoc_macro.c2
6 files changed, 9 insertions, 9 deletions
diff --git a/libmandoc.h b/libmandoc.h
index 63943e5a..198184a0 100644
--- a/libmandoc.h
+++ b/libmandoc.h
@@ -42,7 +42,7 @@ void mandoc_vmsg(enum mandocerr, struct mparse *,
int, int, const char *, ...);
char *mandoc_getarg(struct mparse *, char **, int, int *);
char *mandoc_normdate(struct mparse *, char *, int, int);
-int mandoc_eos(const char *, size_t, int);
+int mandoc_eos(const char *, size_t);
int mandoc_strntoi(const char *, size_t, int);
const char *mandoc_a2msec(const char*);
diff --git a/man.c b/man.c
index 896a19ce..fbf02e74 100644
--- a/man.c
+++ b/man.c
@@ -479,7 +479,7 @@ man_ptext(struct man *man, int line, char *buf, int offs)
*/
assert(i);
- if (mandoc_eos(buf, (size_t)i, 0))
+ if (mandoc_eos(buf, (size_t)i))
man->last->flags |= MAN_EOS;
return(man_descope(man, line, offs));
diff --git a/man_macro.c b/man_macro.c
index d10514b9..bcfdcc55 100644
--- a/man_macro.c
+++ b/man_macro.c
@@ -438,7 +438,7 @@ in_line_eoln(MACRO_PROT_ARGS)
*/
if (n != man->last &&
- mandoc_eos(man->last->string, strlen(man->last->string), 0))
+ mandoc_eos(man->last->string, strlen(man->last->string)))
man->last->flags |= MAN_EOS;
/*
diff --git a/mandoc.c b/mandoc.c
index d2da1e94..5f002bf5 100644
--- a/mandoc.c
+++ b/mandoc.c
@@ -594,10 +594,10 @@ mandoc_normdate(struct mparse *parse, char *in, int ln, int pos)
}
int
-mandoc_eos(const char *p, size_t sz, int enclosed)
+mandoc_eos(const char *p, size_t sz)
{
- const char *q;
- int found;
+ const char *q;
+ int enclosed, found;
if (0 == sz)
return(0);
@@ -608,7 +608,7 @@ mandoc_eos(const char *p, size_t sz, int enclosed)
* propagate outward.
*/
- found = 0;
+ enclosed = found = 0;
for (q = p + (int)sz - 1; q >= p; q--) {
switch (*q) {
case ('\"'):
diff --git a/mdoc.c b/mdoc.c
index 14eadb65..bc977d36 100644
--- a/mdoc.c
+++ b/mdoc.c
@@ -846,7 +846,7 @@ mdoc_ptext(struct mdoc *mdoc, int line, char *buf, int offs)
assert(buf < end);
- if (mandoc_eos(buf+offs, (size_t)(end-buf-offs), 0))
+ if (mandoc_eos(buf+offs, (size_t)(end-buf-offs)))
mdoc->last->flags |= MDOC_EOS;
return(1);
diff --git a/mdoc_macro.c b/mdoc_macro.c
index 9d891ecf..bd529c03 100644
--- a/mdoc_macro.c
+++ b/mdoc_macro.c
@@ -683,7 +683,7 @@ append_delims(struct mdoc *mdoc, int line, int *pos, char *buf)
* knowing which symbols break this behaviour, for
* example, `. ;' shouldn't propagate the double-space.
*/
- if (mandoc_eos(p, strlen(p), 0))
+ if (mandoc_eos(p, strlen(p)))
mdoc->last->flags |= MDOC_EOS;
}