85 #define STR vstring_str 
  101 static void smtpd_expand_unknown(
const char *name)
 
  103     msg_warn(
"unknown macro name \"%s\" in expansion request", name);
 
  108 static const char *smtpd_expand_addr(
VSTRING *buf, 
const char *addr,
 
  109                            const char *name, 
int prefix_len)
 
  120     suffix = name + prefix_len;
 
  135 #define STREQ(x,y) (*(x) == *(y) && strcmp((x), (y)) == 0) 
  139         if ((p = strrchr(addr, 
'@')) != 0) {
 
  154         if ((p = strrchr(addr, 
'@')) != 0) {
 
  167     smtpd_expand_unknown(name);
 
  185     msg_info(
"smtpd_expand_lookup: ${%s}", name);
 
  187 #define STREQN(x,y,n) (*(x) == *(y) && strncmp((x), (y), (n)) == 0) 
  188 #define CONST_LEN(x)  (sizeof(x) - 1) 
  208     return (state->
port);
 
  210     return (state->
addr);
 
  212     return (state->
name);
 
  224     if (time(&now) == (time_t) -1)
 
  226     lt = localtime(&now);
 
  232               "%b %d %H:%M:%S", lt) == 0);
 
  235     smtpd_expand_unknown(name);
 
  243                      const char *
template, 
int flags)
 
  245     return (
mac_expand(result, 
template, flags, 
STR(smtpd_expand_filter),
 
#define MAIL_ATTR_ACT_HELO_NAME
int mac_expand(VSTRING *result, const char *pattern, int flags, const char *filter, MAC_EXP_LOOKUP_FN lookup, void *context)
void smtpd_expand_init(void)
const char * smtpd_expand_lookup(const char *name, int unused_mode, void *context)
#define MAIL_ATTR_ACT_CLIENT_ADDR
#define MAIL_ATTR_SERVER_NAME
#define MAIL_ATTR_ACT_CLIENT_PORT
#define VSTRING_RESET(vp)
char * var_smtpd_exp_filter
void msg_warn(const char *fmt,...)
#define MAIL_ATTR_ACT_CLIENT_NAME
VSTRING * vstring_alloc(ssize_t len)
int smtpd_expand(SMTPD_STATE *state, VSTRING *result, const char *template, int flags)
#define MAIL_ATTR_ACT_REVERSE_CLIENT_NAME
#define vstring_avail(vp)
NORETURN msg_fatal(const char *fmt,...)
#define MAIL_ATTR_LOCALTIME
VSTRING * smtpd_expand_filter
#define VSTRING_SPACE(vp, len)
#define MAIL_ATTR_ACT_CLIENT
VSTRING * vstring_strncpy(VSTRING *vp, const char *src, ssize_t len)
VSTRING * unescape(VSTRING *, const char *)
void msg_info(const char *fmt,...)
#define MAIL_ATTR_S_DOMAIN