From 4c433934a384d19bd29d0468c0f871275f8c7fd0 Mon Sep 17 00:00:00 2001 From: Ingo Schwarze Date: Thu, 3 Nov 2011 20:48:52 +0000 Subject: When .TH sets no data, leave the date field in the page footer blank, do not use the current date. This removes a gratuitous output difference with respect to groff. ok kristaps@ --- man_validate.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'man_validate.c') diff --git a/man_validate.c b/man_validate.c index 587436c4..4c1a72e9 100644 --- a/man_validate.c +++ b/man_validate.c @@ -415,10 +415,12 @@ post_TH(CHKARGS) if (n) n = n->next; - if (n) + if (n && n->string && '\0' != n->string[0]) { pos = n->pos; - m->meta.date = mandoc_normdate - (m->parse, n ? n->string : NULL, line, pos); + m->meta.date = mandoc_normdate + (m->parse, n->string, line, pos); + } else + m->meta.date = mandoc_strdup(""); /* TITLE MSEC DATE ->SOURCE<- VOL */ -- cgit