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

Diff for /mandoc/mdoc_validate.c between version 1.288 and 1.291

version 1.288, 2015/04/19 14:00:20 version 1.291, 2015/04/23 16:17:44
Line 969  post_nm(POST_ARGS)
Line 969  post_nm(POST_ARGS)
         if (NULL != mdoc->meta.name)          if (NULL != mdoc->meta.name)
                 return;                  return;
   
         mdoc_deroff(&mdoc->meta.name, n);          deroff(&mdoc->meta.name, n);
   
         if (NULL == mdoc->meta.name)          if (NULL == mdoc->meta.name)
                 mandoc_msg(MANDOCERR_NM_NONAME, mdoc->parse,                  mandoc_msg(MANDOCERR_NM_NONAME, mdoc->parse,
Line 1051  post_defaults(POST_ARGS)
Line 1051  post_defaults(POST_ARGS)
   
         switch (nn->tok) {          switch (nn->tok) {
         case MDOC_Ar:          case MDOC_Ar:
                 mdoc_word_alloc(mdoc, nn->line, nn->pos, "file");                  roff_word_alloc(mdoc, nn->line, nn->pos, "file");
                 mdoc_word_alloc(mdoc, nn->line, nn->pos, "...");                  roff_word_alloc(mdoc, nn->line, nn->pos, "...");
                 break;                  break;
         case MDOC_Pa:          case MDOC_Pa:
                 /* FALLTHROUGH */                  /* FALLTHROUGH */
         case MDOC_Mt:          case MDOC_Mt:
                 mdoc_word_alloc(mdoc, nn->line, nn->pos, "~");                  roff_word_alloc(mdoc, nn->line, nn->pos, "~");
                 break;                  break;
         default:          default:
                 abort();                  abort();
Line 1076  post_at(POST_ARGS)
Line 1076  post_at(POST_ARGS)
         n = mdoc->last;          n = mdoc->last;
         if (n->child == NULL) {          if (n->child == NULL) {
                 mdoc->next = ROFF_NEXT_CHILD;                  mdoc->next = ROFF_NEXT_CHILD;
                 mdoc_word_alloc(mdoc, n->line, n->pos, "AT&T UNIX");                  roff_word_alloc(mdoc, n->line, n->pos, "AT&T UNIX");
                 mdoc->last = n;                  mdoc->last = n;
                 return;                  return;
         }          }
Line 1562  post_root(POST_ARGS)
Line 1562  post_root(POST_ARGS)
         /* Check that we begin with a proper `Sh'. */          /* Check that we begin with a proper `Sh'. */
   
         n = mdoc->first->child;          n = mdoc->first->child;
         while (n != NULL && mdoc_macros[n->tok].flags & MDOC_PROLOGUE)          while (n != NULL && n->tok != TOKEN_NONE &&
               mdoc_macros[n->tok].flags & MDOC_PROLOGUE)
                 n = n->next;                  n = n->next;
   
         if (n == NULL)          if (n == NULL)
Line 1882  post_sh_head(POST_ARGS)
Line 1883  post_sh_head(POST_ARGS)
   
         secname = NULL;          secname = NULL;
         sec = SEC_CUSTOM;          sec = SEC_CUSTOM;
         mdoc_deroff(&secname, mdoc->last);          deroff(&secname, mdoc->last);
         sec = NULL == secname ? SEC_CUSTOM : a2sec(secname);          sec = NULL == secname ? SEC_CUSTOM : a2sec(secname);
   
         /* The NAME should be first. */          /* The NAME should be first. */
Line 2131  post_dd(POST_ARGS)
Line 2132  post_dd(POST_ARGS)
         }          }
   
         datestr = NULL;          datestr = NULL;
         mdoc_deroff(&datestr, n);          deroff(&datestr, n);
         if (mdoc->quick)          if (mdoc->quick)
                 mdoc->meta.date = datestr;                  mdoc->meta.date = datestr;
         else {          else {
Line 2266  post_os(POST_ARGS)
Line 2267  post_os(POST_ARGS)
   
         free(mdoc->meta.os);          free(mdoc->meta.os);
         mdoc->meta.os = NULL;          mdoc->meta.os = NULL;
         mdoc_deroff(&mdoc->meta.os, n);          deroff(&mdoc->meta.os, n);
         if (mdoc->meta.os)          if (mdoc->meta.os)
                 goto out;                  goto out;
   
Line 2315  post_ex(POST_ARGS)
Line 2316  post_ex(POST_ARGS)
         }          }
   
         mdoc->next = ROFF_NEXT_CHILD;          mdoc->next = ROFF_NEXT_CHILD;
         mdoc_word_alloc(mdoc, n->line, n->pos, mdoc->meta.name);          roff_word_alloc(mdoc, n->line, n->pos, mdoc->meta.name);
         mdoc->last = n;          mdoc->last = n;
 }  }
   

Legend:
Removed from v.1.288  
changed lines
  Added in v.1.291

CVSweb