[BACK]Return to eqn.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / mandoc

Diff for /src/usr.bin/mandoc/eqn.c between version 1.42 and 1.43

version 1.42, 2018/12/12 21:54:30 version 1.43, 2018/12/13 03:40:09
Line 28 
Line 28 
 #include "mandoc_aux.h"  #include "mandoc_aux.h"
 #include "mandoc.h"  #include "mandoc.h"
 #include "roff.h"  #include "roff.h"
 #include "tbl.h"  
 #include "libmandoc.h"  #include "libmandoc.h"
 #include "libroff.h"  #include "eqn_parse.h"
   
 #define EQN_NEST_MAX     128 /* maximum nesting of defines */  #define EQN_NEST_MAX     128 /* maximum nesting of defines */
 #define STRNEQ(p1, sz1, p2, sz2) \  #define STRNEQ(p1, sz1, p2, sz2) \
Line 283 
Line 282 
         MODE_TOK          MODE_TOK
 };  };
   
   struct  eqn_def {
           char             *key;
           size_t            keysz;
           char             *val;
           size_t            valsz;
   };
   
 static  struct eqn_box  *eqn_box_alloc(struct eqn_node *, struct eqn_box *);  static  struct eqn_box  *eqn_box_alloc(struct eqn_node *, struct eqn_box *);
 static  struct eqn_box  *eqn_box_makebinary(struct eqn_node *,  static  struct eqn_box  *eqn_box_makebinary(struct eqn_node *,
                                 struct eqn_box *);                                  struct eqn_box *);
Line 467 
Line 473 
 void  void
 eqn_box_free(struct eqn_box *bp)  eqn_box_free(struct eqn_box *bp)
 {  {
           if (bp == NULL)
                   return;
   
         if (bp->first)          if (bp->first)
                 eqn_box_free(bp->first);                  eqn_box_free(bp->first);
Line 1090 
Line 1098 
 eqn_free(struct eqn_node *p)  eqn_free(struct eqn_node *p)
 {  {
         int              i;          int              i;
   
           if (p == NULL)
                   return;
   
         for (i = 0; i < (int)p->defsz; i++) {          for (i = 0; i < (int)p->defsz; i++) {
                 free(p->defs[i].key);                  free(p->defs[i].key);

Legend:
Removed from v.1.42  
changed lines
  Added in v.1.43