/[mailutils]/mailutils/mh/mh_format.c
ViewVC logotype

Diff of /mailutils/mh/mh_format.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.31 by gray, Fri Feb 14 11:43:46 2003 UTC revision 1.32 by gray, Tue Feb 18 15:22:24 2003 UTC
# Line 871  static void Line 871  static void
871  builtin_me (struct mh_machine *mach)  builtin_me (struct mh_machine *mach)
872  {  {
873    char *s = mh_my_email ();    char *s = mh_my_email ();
874    strobj_free (&mach->arg_str);    strobj_realloc (&mach->arg_str, strlen (s) + 3);
875    strobj_create (&mach->arg_str, s);    sprintf (strobj_ptr (&mach->arg_str), "<%s>", s);
876  }  }
877    
878  static void  static void
# Line 1708  builtin_formataddr (struct mh_machine *m Line 1708  builtin_formataddr (struct mh_machine *m
1708    address_t addr, dest;    address_t addr, dest;
1709    size_t size;    size_t size;
1710        
1711    if (strobj_is_null (&mach->reg_str))    if (strobj_len (&mach->reg_str) == 0)
1712      dest = NULL;      dest = NULL;
1713    else if (address_create (&dest, strobj_ptr (&mach->reg_str)))    else if (address_create (&dest, strobj_ptr (&mach->reg_str)))
1714      return;      return;
# Line 1935  mh_builtin_t builtin_tab[] = { Line 1935  mh_builtin_t builtin_tab[] = {
1935    { "divide",   builtin_divide,   mhtype_num,  mhtype_num },    { "divide",   builtin_divide,   mhtype_num,  mhtype_num },
1936    { "modulo",   builtin_modulo,   mhtype_num,  mhtype_num },    { "modulo",   builtin_modulo,   mhtype_num,  mhtype_num },
1937    { "num",      builtin_num,      mhtype_num,  mhtype_num },    { "num",      builtin_num,      mhtype_num,  mhtype_num },
1938    { "lit",      builtin_lit,      mhtype_str,  mhtype_str, 1 },    { "lit",      builtin_lit,      mhtype_str,  mhtype_str,  MHA_OPT_CLEAR },
1939    { "getenv",   builtin_getenv,   mhtype_str,  mhtype_str },    { "getenv",   builtin_getenv,   mhtype_str,  mhtype_str },
1940    { "profile",  builtin_profile,  mhtype_str,  mhtype_str },    { "profile",  builtin_profile,  mhtype_str,  mhtype_str },
1941    { "nonzero",  builtin_nonzero,  mhtype_num,  mhtype_num, 1 },    { "nonzero",  builtin_nonzero,  mhtype_num,  mhtype_num,  MHA_OPTARG },
1942    { "zero",     builtin_zero,     mhtype_num,  mhtype_num, 1 },    { "zero",     builtin_zero,     mhtype_num,  mhtype_num,  MHA_OPTARG },
1943    { "null",     builtin_null,     mhtype_num,  mhtype_str, 1 },    { "null",     builtin_null,     mhtype_num,  mhtype_str,  MHA_OPTARG },
1944    { "nonnull",  builtin_nonnull,  mhtype_num,  mhtype_str, 1 },    { "nonnull",  builtin_nonnull,  mhtype_num,  mhtype_str,  MHA_OPTARG },
1945    { "comp",     builtin_comp,     mhtype_num,  mhtype_str },    { "comp",     builtin_comp,     mhtype_num,  mhtype_str,  MHA_OPTARG },
1946    { "compval",  builtin_compval,  mhtype_num,  mhtype_str },    { "compval",  builtin_compval,  mhtype_num,  mhtype_str },      
1947    { "trim",     builtin_trim,     mhtype_str,  mhtype_str, 1 },    { "trim",     builtin_trim,     mhtype_str,  mhtype_str,  MHA_OPTARG },
1948    { "putstr",   builtin_putstr,   mhtype_none,  mhtype_str, 1 },    { "putstr",   builtin_putstr,   mhtype_none,  mhtype_str, MHA_OPTARG },
1949    { "putstrf",  builtin_putstrf,  mhtype_none,  mhtype_str, 1 },    { "putstrf",  builtin_putstrf,  mhtype_none,  mhtype_str, MHA_OPTARG },
1950    { "putnum",   builtin_putnum,   mhtype_none,  mhtype_num, 1 },    { "putnum",   builtin_putnum,   mhtype_none,  mhtype_num, MHA_OPTARG },
1951    { "putnumf",  builtin_putnumf,  mhtype_none,  mhtype_num, 1 },    { "putnumf",  builtin_putnumf,  mhtype_none,  mhtype_num, MHA_OPTARG },
1952    { "sec",      builtin_sec,      mhtype_num,  mhtype_str },    { "sec",      builtin_sec,      mhtype_num,  mhtype_str },
1953    { "min",      builtin_min,      mhtype_num,  mhtype_str },    { "min",      builtin_min,      mhtype_num,  mhtype_str },
1954    { "hour",     builtin_hour,     mhtype_num,  mhtype_str },    { "hour",     builtin_hour,     mhtype_num,  mhtype_str },
# Line 1986  mh_builtin_t builtin_tab[] = { Line 1986  mh_builtin_t builtin_tab[] = {
1986    { "path",     builtin_path,     mhtype_str,  mhtype_str },    { "path",     builtin_path,     mhtype_str,  mhtype_str },
1987    { "ingrp",    builtin_ingrp,    mhtype_num,  mhtype_str },    { "ingrp",    builtin_ingrp,    mhtype_num,  mhtype_str },
1988    { "gname",    builtin_gname,    mhtype_str,  mhtype_str},    { "gname",    builtin_gname,    mhtype_str,  mhtype_str},
1989    { "formataddr", builtin_formataddr, mhtype_none, mhtype_str, 1 },    { "formataddr", builtin_formataddr, mhtype_none, mhtype_str, MHA_OPTARG },
1990    { "putaddr",  builtin_putaddr,  mhtype_none, mhtype_str },    { "putaddr",  builtin_putaddr,  mhtype_none, mhtype_str },
1991    { "unre",     builtin_unre,     mhtype_str,  mhtype_str },    { "unre",     builtin_unre,     mhtype_str,  mhtype_str },
1992    { "rcpt",     builtin_rcpt,     mhtype_num,  mhtype_str },    { "rcpt",     builtin_rcpt,     mhtype_num,  mhtype_str },
1993    { "concat",   builtin_concat,   mhtype_none, mhtype_str,     1 },    { "concat",   builtin_concat,   mhtype_none, mhtype_str,     MHA_OPTARG },
1994    { "printhdr", builtin_printhdr, mhtype_none, mhtype_str },    { "printhdr", builtin_printhdr, mhtype_none, mhtype_str },
1995    { "in_reply_to", builtin_in_reply_to, mhtype_str,  mhtype_none },    { "in_reply_to", builtin_in_reply_to, mhtype_str,  mhtype_none },
1996    { "references", builtin_references, mhtype_str,  mhtype_none },    { "references", builtin_references, mhtype_str,  mhtype_none },

Legend:
Removed from v.1.31  
changed lines
  Added in v.1.32

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26