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

Diff for /mandoc/eqn.c between version 1.29 and 1.30

version 1.29, 2011/07/22 14:55:07 version 1.30, 2011/07/22 14:59:02
Line 126  enum eqnpartt {
Line 126  enum eqnpartt {
         EQN_DEFINE = 0,          EQN_DEFINE = 0,
         EQN_SET,          EQN_SET,
         EQN_UNDEF,          EQN_UNDEF,
           EQN_GFONT,
         EQN_GSIZE,          EQN_GSIZE,
         EQN__MAX          EQN__MAX
 };  };
Line 136  static struct eqn_box *eqn_box_alloc(struct eqn_node *
Line 137  static struct eqn_box *eqn_box_alloc(struct eqn_node *
 static  void             eqn_box_free(struct eqn_box *);  static  void             eqn_box_free(struct eqn_box *);
 static  struct eqn_def  *eqn_def_find(struct eqn_node *,  static  struct eqn_def  *eqn_def_find(struct eqn_node *,
                                 const char *, size_t);                                  const char *, size_t);
   static  int              eqn_do_gfont(struct eqn_node *);
 static  int              eqn_do_gsize(struct eqn_node *);  static  int              eqn_do_gsize(struct eqn_node *);
 static  int              eqn_do_define(struct eqn_node *);  static  int              eqn_do_define(struct eqn_node *);
 static  int              eqn_do_set(struct eqn_node *);  static  int              eqn_do_set(struct eqn_node *);
Line 152  static const struct eqnpart eqnparts[EQN__MAX] = {
Line 154  static const struct eqnpart eqnparts[EQN__MAX] = {
         { { "define", 6 }, eqn_do_define }, /* EQN_DEFINE */          { { "define", 6 }, eqn_do_define }, /* EQN_DEFINE */
         { { "set", 3 }, eqn_do_set }, /* EQN_SET */          { { "set", 3 }, eqn_do_set }, /* EQN_SET */
         { { "undef", 5 }, eqn_do_undef }, /* EQN_UNDEF */          { { "undef", 5 }, eqn_do_undef }, /* EQN_UNDEF */
         { { "gsize", 5 }, eqn_do_gsize }, /* EQN_UNDEF */          { { "gfont", 5 }, eqn_do_gfont }, /* EQN_GFONT */
           { { "gsize", 5 }, eqn_do_gsize }, /* EQN_GSIZE */
 };  };
   
 static  const struct eqnstr eqnmarks[EQNMARK__MAX] = {  static  const struct eqnstr eqnmarks[EQNMARK__MAX] = {
Line 761  eqn_do_define(struct eqn_node *ep)
Line 764  eqn_do_define(struct eqn_node *ep)
         def->val = mandoc_realloc(def->val, sz + 1);          def->val = mandoc_realloc(def->val, sz + 1);
         memcpy(def->val, start, sz);          memcpy(def->val, start, sz);
         def->val[(int)sz] = '\0';          def->val[(int)sz] = '\0';
           return(1);
   }
   
   static int
   eqn_do_gfont(struct eqn_node *ep)
   {
           const char      *start;
   
           if (NULL == (start = eqn_nextrawtok(ep, NULL))) {
                   EQN_MSG(MANDOCERR_EQNEOF, ep);
                   return(0);
           }
         return(1);          return(1);
 }  }
   

Legend:
Removed from v.1.29  
changed lines
  Added in v.1.30

CVSweb