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

Diff for /mandoc/mdoc.c between version 1.194 and 1.197

version 1.194, 2011/07/27 12:43:02 version 1.197, 2012/05/27 17:48:57
Line 160  mdoc_alloc1(struct mdoc *mdoc)
Line 160  mdoc_alloc1(struct mdoc *mdoc)
         mdoc->last = mandoc_calloc(1, sizeof(struct mdoc_node));          mdoc->last = mandoc_calloc(1, sizeof(struct mdoc_node));
         mdoc->first = mdoc->last;          mdoc->first = mdoc->last;
         mdoc->last->type = MDOC_ROOT;          mdoc->last->type = MDOC_ROOT;
           mdoc->last->tok = MDOC_MAX;
         mdoc->next = MDOC_NEXT_CHILD;          mdoc->next = MDOC_NEXT_CHILD;
 }  }
   
Line 196  mdoc_free(struct mdoc *mdoc)
Line 197  mdoc_free(struct mdoc *mdoc)
  * Allocate volatile and non-volatile parse resources.   * Allocate volatile and non-volatile parse resources.
  */   */
 struct mdoc *  struct mdoc *
 mdoc_alloc(struct roff *roff, struct mparse *parse)  mdoc_alloc(struct roff *roff, struct mparse *parse, char *defos)
 {  {
         struct mdoc     *p;          struct mdoc     *p;
   
         p = mandoc_calloc(1, sizeof(struct mdoc));          p = mandoc_calloc(1, sizeof(struct mdoc));
   
         p->parse = parse;          p->parse = parse;
           p->defos = defos;
         p->roff = roff;          p->roff = roff;
   
         mdoc_hash_init();          mdoc_hash_init();
Line 570  mdoc_word_alloc(struct mdoc *m, int line, int pos, con
Line 572  mdoc_word_alloc(struct mdoc *m, int line, int pos, con
         struct mdoc_node *n;          struct mdoc_node *n;
   
         n = node_alloc(m, line, pos, MDOC_MAX, MDOC_TEXT);          n = node_alloc(m, line, pos, MDOC_MAX, MDOC_TEXT);
         n->string = mandoc_strdup(p);          n->string = roff_strdup(m->roff, p);
   
         if ( ! node_append(m, n))          if ( ! node_append(m, n))
                 return(0);                  return(0);

Legend:
Removed from v.1.194  
changed lines
  Added in v.1.197

CVSweb