[BACK]Return to man_validate.c CVS log [TXT][DIR] Up to [cvsweb.bsd.lv] / mandoc

Diff for /mandoc/man_validate.c between version 1.133 and 1.134

version 1.133, 2017/07/26 10:33:34 version 1.134, 2018/04/11 17:11:13
Line 1 
Line 1 
 /*      $OpenBSD$ */  /*      $OpenBSD$ */
 /*  /*
  * Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv>   * Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv>
  * Copyright (c) 2010, 2012-2017 Ingo Schwarze <schwarze@openbsd.org>   * Copyright (c) 2010, 2012-2018 Ingo Schwarze <schwarze@openbsd.org>
  *   *
  * Permission to use, copy, modify, and distribute this software for any   * Permission to use, copy, modify, and distribute this software for any
  * purpose with or without fee is hereby granted, provided that the above   * purpose with or without fee is hereby granted, provided that the above
Line 120  man_node_validate(struct roff_man *man)
Line 120  man_node_validate(struct roff_man *man)
         case ROFFT_ROOT:          case ROFFT_ROOT:
                 check_root(man, n);                  check_root(man, n);
                 break;                  break;
           case ROFFT_COMMENT:
         case ROFFT_EQN:          case ROFFT_EQN:
         case ROFFT_TBL:          case ROFFT_TBL:
                 break;                  break;
Line 149  man_node_validate(struct roff_man *man)
Line 150  man_node_validate(struct roff_man *man)
 static void  static void
 check_root(CHKARGS)  check_root(CHKARGS)
 {  {
   
         assert((man->flags & (MAN_BLINE | MAN_ELINE)) == 0);          assert((man->flags & (MAN_BLINE | MAN_ELINE)) == 0);
   
         if (NULL == man->first->child)          if (n->last == NULL || n->last->type == ROFFT_COMMENT)
                 mandoc_msg(MANDOCERR_DOC_EMPTY, man->parse,                  mandoc_msg(MANDOCERR_DOC_EMPTY, man->parse,
                     n->line, n->pos, NULL);                      n->line, n->pos, NULL);
         else          else

Legend:
Removed from v.1.133  
changed lines
  Added in v.1.134

CVSweb