diff options
author | Kristaps Dzonsons <kristaps@bsd.lv> | 2011-07-01 13:46:39 +0000 |
---|---|---|
committer | Kristaps Dzonsons <kristaps@bsd.lv> | 2011-07-01 13:46:39 +0000 |
commit | 142f3f33ae70bff865d1359c11d71423346ca94c (patch) | |
tree | 9419d1aec41bc627313ded3c44ca7fcdfa960370 /makewhatis.c | |
parent | 78860d6998411b54eb45efb7169550d999084fa8 (diff) | |
download | mandoc-142f3f33ae70bff865d1359c11d71423346ca94c.tar.gz |
Added `Er' in ERRORS scan to makewhatis.
Diffstat (limited to 'makewhatis.c')
-rw-r--r-- | makewhatis.c | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/makewhatis.c b/makewhatis.c index 8a812179..9a06783c 100644 --- a/makewhatis.c +++ b/makewhatis.c @@ -57,6 +57,7 @@ #define TYPE_XREF 0x200 #define TYPE_PATH 0x400 #define TYPE_ENV 0x800 +#define TYPE_ERR 0x1000 /* Buffer for storing growable data. */ @@ -87,6 +88,7 @@ static int pman_node(MAN_ARGS); static void pmdoc_node(MDOC_ARGS); static void pmdoc_An(MDOC_ARGS); static void pmdoc_Cd(MDOC_ARGS); +static void pmdoc_Er(MDOC_ARGS); static void pmdoc_Ev(MDOC_ARGS); static void pmdoc_Fd(MDOC_ARGS); static void pmdoc_In(MDOC_ARGS); @@ -123,7 +125,7 @@ static const pmdoc_nf mdocs[MDOC_MAX] = { pmdoc_Cd, /* Cd */ NULL, /* Cm */ NULL, /* Dv */ - NULL, /* Er */ + pmdoc_Er, /* Er */ pmdoc_Ev, /* Ev */ NULL, /* Ex */ NULL, /* Fa */ @@ -766,6 +768,18 @@ pmdoc_Nd(MDOC_ARGS) /* ARGSUSED */ static void +pmdoc_Er(MDOC_ARGS) +{ + + if (SEC_ERRORS != n->sec) + return; + + buf_appendmdoc(buf, n->child, 0); + hash_put(hash, buf, TYPE_ERR); +} + +/* ARGSUSED */ +static void pmdoc_Ev(MDOC_ARGS) { |