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

Diff for /docbook2mdoc/node.c between version 1.11 and 1.12

version 1.11, 2019/04/12 19:14:50 version 1.12, 2019/04/13 13:06:35
Line 105  static const struct nodeprop properties[] = {
Line 105  static const struct nodeprop properties[] = {
         { "preface",            CLASS_BLOCK },          { "preface",            CLASS_BLOCK },
         { "programlisting",     CLASS_BLOCK },          { "programlisting",     CLASS_BLOCK },
         { "prompt",             CLASS_TRANS },          { "prompt",             CLASS_TRANS },
           { "pubdate",            CLASS_TRANS },
         { "quote",              CLASS_ENCL },          { "quote",              CLASS_ENCL },
         { "refclass",           CLASS_TRANS },          { "refclass",           CLASS_TRANS },
         { "refdescriptor",      CLASS_TRANS },          { "refdescriptor",      CLASS_TRANS },
Line 340  pnode_findfirst(struct pnode *n, enum nodeid node)
Line 341  pnode_findfirst(struct pnode *n, enum nodeid node)
 {  {
         struct pnode    *nc, *res;          struct pnode    *nc, *res;
   
           if (n == NULL)
                   return NULL;
         if (n->node == node)          if (n->node == node)
                 return n;                  return n;
         TAILQ_FOREACH(nc, &n->childq, child)          TAILQ_FOREACH(nc, &n->childq, child)
                 if ((res = pnode_findfirst(nc, node)) != NULL)                  if ((res = pnode_findfirst(nc, node)) != NULL)
                         return res;                          return res;
         return NULL;          return NULL;
   }
   
   /*
    * Like pnode_findfirst(), but also take the node out of the tree.
    */
   struct pnode *
   pnode_takefirst(struct pnode *n, enum nodeid node)
   {
           struct pnode    *nc;
   
           if ((nc = pnode_findfirst(n, node)) != NULL && nc->parent != NULL)
                   TAILQ_REMOVE(&nc->parent->childq, nc, child);
           return nc;
 }  }

Legend:
Removed from v.1.11  
changed lines
  Added in v.1.12

CVSweb