=================================================================== RCS file: /cvs/mandoc/mandoc.c,v retrieving revision 1.61 retrieving revision 1.62 diff -u -p -r1.61 -r1.62 --- mandoc/mandoc.c 2011/11/06 14:43:14 1.61 +++ mandoc/mandoc.c 2011/12/03 16:08:51 1.62 @@ -1,4 +1,4 @@ -/* $Id: mandoc.c,v 1.61 2011/11/06 14:43:14 kristaps Exp $ */ +/* $Id: mandoc.c,v 1.62 2011/12/03 16:08:51 schwarze Exp $ */ /* * Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons * Copyright (c) 2011 Ingo Schwarze @@ -623,9 +623,10 @@ mandoc_normdate(struct mparse *parse, char *in, int ln mandoc_msg(MANDOCERR_NODATE, parse, ln, pos, NULL); time(&t); } + else if (a2time(&t, "%Y-%m-%d", in)) + t = 0; else if (!a2time(&t, "$" "Mdocdate: %b %d %Y $", in) && - !a2time(&t, "%b %d, %Y", in) && - !a2time(&t, "%Y-%m-%d", in)) { + !a2time(&t, "%b %d, %Y", in)) { mandoc_msg(MANDOCERR_BADDATE, parse, ln, pos, NULL); t = 0; }