source@mandoc.bsd.lv
 help / color / mirror / Atom feed
* mdocml: Make sure that the manual section defaults to `1' if it's unset.
@ 2010-12-01 16:38 kristaps
  0 siblings, 0 replies; only message in thread
From: kristaps @ 2010-12-01 16:38 UTC (permalink / raw)
  To: source

Log Message:
-----------
Make sure that the manual section defaults to `1' if it's unset.  This 
behaviour only happens if `Dt' isn't specified, which can be exhibited 
by running mandoc -mdoc on a man manual.

Modified Files:
--------------
    mdocml:
        mdoc.c

Revision Data
-------------
Index: mdoc.c
===================================================================
RCS file: /usr/vhosts/mdocml.bsd.lv/cvs/mdocml/mdoc.c,v
retrieving revision 1.166
retrieving revision 1.167
diff -Lmdoc.c -Lmdoc.c -u -p -r1.166 -r1.167
--- mdoc.c
+++ mdoc.c
@@ -286,6 +286,8 @@ mdoc_macro(MACRO_PROT_ARGS)
 			! (MDOC_PBODY & m->flags)) {
 		if ( ! mdoc_pmsg(m, line, ppos, MANDOCERR_BADPROLOG))
 			return(0);
+		if (NULL == m->meta.msec)
+			m->meta.msec = mandoc_strdup("1");
 		if (NULL == m->meta.title)
 			m->meta.title = mandoc_strdup("UNKNOWN");
 		if (NULL == m->meta.vol)
--
 To unsubscribe send an email to source+unsubscribe@mdocml.bsd.lv

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2010-12-01 16:38 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-12-01 16:38 mdocml: Make sure that the manual section defaults to `1' if it's unset kristaps

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).