summaryrefslogtreecommitdiffstats
path: root/man_action.c
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2010-05-15 15:54:39 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2010-05-15 15:54:39 +0000
commitb9297c29623c1e4db9a654cff80d1ac016fdbaee (patch)
tree2f593f482089d568f7cf7614873b114e88046755 /man_action.c
parented04d894e573be8a07ec7f68bb5245f83ce49beb (diff)
downloadmandoc-b9297c29623c1e4db9a654cff80d1ac016fdbaee.tar.gz
Removed restriction on integer manual sections in -man.
Diffstat (limited to 'man_action.c')
-rw-r--r--man_action.c14
1 files changed, 3 insertions, 11 deletions
diff --git a/man_action.c b/man_action.c
index 48f4259e..66488d64 100644
--- a/man_action.c
+++ b/man_action.c
@@ -144,8 +144,6 @@ static int
post_TH(struct man *m)
{
struct man_node *n;
- char *ep;
- long lval;
if (m->meta.title)
free(m->meta.title);
@@ -154,8 +152,8 @@ post_TH(struct man *m)
if (m->meta.source)
free(m->meta.source);
- m->meta.title = m->meta.vol = m->meta.source = NULL;
- m->meta.msec = 0;
+ m->meta.title = m->meta.vol =
+ m->meta.msec = m->meta.source = NULL;
m->meta.date = 0;
/* ->TITLE<- MSEC DATE SOURCE VOL */
@@ -168,12 +166,7 @@ post_TH(struct man *m)
n = n->next;
assert(n);
-
- lval = strtol(n->string, &ep, 10);
- if (n->string[0] != '\0' && *ep == '\0')
- m->meta.msec = (int)lval;
- else if ( ! man_nwarn(m, n, WMSEC))
- return(0);
+ m->meta.msec = mandoc_strdup(n->string);
/* TITLE MSEC ->DATE<- SOURCE VOL */
@@ -181,7 +174,6 @@ post_TH(struct man *m)
if (n) {
m->meta.date = mandoc_a2time
(MTIME_ISO_8601, n->string);
-
if (0 == m->meta.date) {
if ( ! man_nwarn(m, n, WDATE))
return(0);