"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/macros.h" between
exim-4.91.tar.xz and exim-4.92.tar.xz

About: Exim is a message transfer agent (MTA).

macros.h  (exim-4.91.tar.xz):macros.h  (exim-4.92.tar.xz)
skipping to change at line 25 skipping to change at line 25
#define nelem(arr) (sizeof(arr) / sizeof(*arr)) #define nelem(arr) (sizeof(arr) / sizeof(*arr))
/* Maximum of two items */ /* Maximum of two items */
#ifndef MAX #ifndef MAX
# define MAX(a,b) ((a) > (b) ? (a) : (b)) # define MAX(a,b) ((a) > (b) ? (a) : (b))
#endif #endif
/* When running in the test harness, the load average is fudged. */ /* When running in the test harness, the load average is fudged. */
#define OS_GETLOADAVG() \ #define OS_GETLOADAVG() \
(running_in_test_harness? (test_harness_load_avg += 10) : os_getloadavg()) (f.running_in_test_harness? (test_harness_load_avg += 10) : os_getloadavg())
/* The address_item structure has a struct full of 1-bit flags. These macros /* The address_item structure has a struct full of 1-bit flags. These macros
manipulate them. */ manipulate them. */
#define setflag(addr, flagname) addr->flags.flagname = TRUE #define setflag(addr, flagname) addr->flags.flagname = TRUE
#define clearflag(addr, flagname) addr->flags.flagname = FALSE #define clearflag(addr, flagname) addr->flags.flagname = FALSE
#define testflag(addr, flagname) (addr->flags.flagname) #define testflag(addr, flagname) (addr->flags.flagname)
#define copyflag(addrnew, addrold, flagname) \ #define copyflag(addrnew, addrold, flagname) \
skipping to change at line 80 skipping to change at line 80
((uschar)(c) > 127 && print_topbitchars)) ((uschar)(c) > 127 && print_topbitchars))
/* Convenience for testing strings */ /* Convenience for testing strings */
#define streqic(Foo, Bar) (strcmpic(Foo, Bar) == 0) #define streqic(Foo, Bar) (strcmpic(Foo, Bar) == 0)
/* When built with TLS support, the act of flushing SMTP output becomes /* When built with TLS support, the act of flushing SMTP output becomes
a no-op once an SSL session is in progress. */ a no-op once an SSL session is in progress. */
#ifdef SUPPORT_TLS #ifdef SUPPORT_TLS
#define mac_smtp_fflush() if (tls_in.active < 0) fflush(smtp_out); #define mac_smtp_fflush() if (tls_in.active.sock < 0) fflush(smtp_out);
#else #else
#define mac_smtp_fflush() fflush(smtp_out); #define mac_smtp_fflush() fflush(smtp_out);
#endif #endif
/* Define which ends of pipes are for reading and writing, as some systems /* Define which ends of pipes are for reading and writing, as some systems
don't make the file descriptors two-way. */ don't make the file descriptors two-way. */
#define pipe_read 0 #define pipe_read 0
#define pipe_write 1 #define pipe_write 1
skipping to change at line 354 skipping to change at line 354
/* IOTA allows us to keep an implicit sequential count, like a simple enum, /* IOTA allows us to keep an implicit sequential count, like a simple enum,
but we can have sequentially numbered identifiers which are not declared but we can have sequentially numbered identifiers which are not declared
sequentially. We use this for more compact declarations of bit indexes and sequentially. We use this for more compact declarations of bit indexes and
masks, alternating between sequential bit index and corresponding mask. */ masks, alternating between sequential bit index and corresponding mask. */
#define IOTA(iota) (__LINE__ - iota) #define IOTA(iota) (__LINE__ - iota)
#define IOTA_INIT(zero) (__LINE__ - zero + 1) #define IOTA_INIT(zero) (__LINE__ - zero + 1)
/* Options bits for debugging. DEBUG_BIT() declares both a bit index and the /* Options bits for debugging. DEBUG_BIT() declares both a bit index and the
corresponding mask. Di_all is a special value recognized by decode_bits(). corresponding mask. Di_all is a special value recognized by decode_bits().
These must match the debug_options table in globals.c .
Exim's code assumes in a number of places that the debug_selector is one Exim's code assumes in a number of places that the debug_selector is one
word, and this is exposed in the local_scan ABI. The D_v and D_local_scan bit word, and this is exposed in the local_scan ABI. The D_v and D_local_scan bit
masks are part of the local_scan API so are #defined in local_scan.h */ masks are part of the local_scan API so are #defined in local_scan.h */
#define DEBUG_BIT(name) Di_##name = IOTA(Di_iota), D_##name = BIT(Di_##name) #define DEBUG_BIT(name) Di_##name = IOTA(Di_iota), D_##name = BIT(Di_##name)
enum { enum {
Di_all = -1, Di_all = -1,
Di_v = 0, Di_v = 0,
skipping to change at line 383 skipping to change at line 384
DEBUG_BIT(expand), DEBUG_BIT(expand),
DEBUG_BIT(filter), DEBUG_BIT(filter),
DEBUG_BIT(hints_lookup), DEBUG_BIT(hints_lookup),
DEBUG_BIT(host_lookup), DEBUG_BIT(host_lookup),
DEBUG_BIT(ident), DEBUG_BIT(ident),
DEBUG_BIT(interface), DEBUG_BIT(interface),
DEBUG_BIT(lists), DEBUG_BIT(lists),
DEBUG_BIT(load), DEBUG_BIT(load),
DEBUG_BIT(lookup), DEBUG_BIT(lookup),
DEBUG_BIT(memory), DEBUG_BIT(memory),
DEBUG_BIT(noutf8),
DEBUG_BIT(pid), DEBUG_BIT(pid),
DEBUG_BIT(process_info), DEBUG_BIT(process_info),
DEBUG_BIT(queue_run), DEBUG_BIT(queue_run),
DEBUG_BIT(receive), DEBUG_BIT(receive),
DEBUG_BIT(resolver), DEBUG_BIT(resolver),
DEBUG_BIT(retry), DEBUG_BIT(retry),
DEBUG_BIT(rewrite), DEBUG_BIT(rewrite),
DEBUG_BIT(route), DEBUG_BIT(route),
DEBUG_BIT(timestamp), DEBUG_BIT(timestamp),
DEBUG_BIT(tls), DEBUG_BIT(tls),
skipping to change at line 404 skipping to change at line 406
DEBUG_BIT(uid), DEBUG_BIT(uid),
DEBUG_BIT(verify), DEBUG_BIT(verify),
}; };
/* Multi-bit debug masks */ /* Multi-bit debug masks */
#define D_all 0xffffffff #define D_all 0xffffffff
#define D_any (D_all & \ #define D_any (D_all & \
~(D_v | \ ~(D_v | \
D_noutf8 | \
D_pid | \ D_pid | \
D_timestamp) ) D_timestamp) )
#define D_default (0xffffffff & \ #define D_default (0xffffffff & \
~(D_expand | \ ~(D_expand | \
D_filter | \ D_filter | \
D_interface | \ D_interface | \
D_load | \ D_load | \
D_local_scan | \ D_local_scan | \
D_memory | \ D_memory | \
D_noutf8 | \
D_pid | \ D_pid | \
D_timestamp | \ D_timestamp | \
D_resolver)) D_resolver))
/* Options bits for logging. Those that have values < BITWORDSIZE can be used /* Options bits for logging. Those that have values < BITWORDSIZE can be used
in calls to log_write(). The others are put into later words in log_selector in calls to log_write(). The others are put into later words in log_selector
and are only ever tested independently, so they do not need bit mask and are only ever tested independently, so they do not need bit mask
declarations. The Li_all value is recognized specially by decode_bits(). */ declarations. The Li_all value is recognized specially by decode_bits(). */
#define LOG_BIT(name) Li_##name = IOTA(Li_iota), L_##name = BIT(Li_##name) #define LOG_BIT(name) Li_##name = IOTA(Li_iota), L_##name = BIT(Li_##name)
skipping to change at line 461 skipping to change at line 465
Li_dkim, Li_dkim,
Li_dkim_verbose, Li_dkim_verbose,
Li_dnssec, Li_dnssec,
Li_ident_timeout, Li_ident_timeout,
Li_incoming_interface, Li_incoming_interface,
Li_incoming_port, Li_incoming_port,
Li_millisec, Li_millisec,
Li_outgoing_interface, Li_outgoing_interface,
Li_outgoing_port, Li_outgoing_port,
Li_pid, Li_pid,
Li_pipelining,
Li_proxy, Li_proxy,
Li_queue_time, Li_queue_time,
Li_queue_time_overall, Li_queue_time_overall,
Li_receive_time, Li_receive_time,
Li_received_sender, Li_received_sender,
Li_received_recipients, Li_received_recipients,
Li_rejected_header, Li_rejected_header,
Li_return_path_on_delivery, Li_return_path_on_delivery,
Li_sender_on_delivery, Li_sender_on_delivery,
Li_sender_verify_fail, Li_sender_verify_fail,
skipping to change at line 542 skipping to change at line 547
#define ERRNO_CONNECTTIMEOUT (-43) /* Used internally in smtp transport */ #define ERRNO_CONNECTTIMEOUT (-43) /* Used internally in smtp transport */
#define ERRNO_RCPT4XX (-44) /* RCPT gave 4xx error */ #define ERRNO_RCPT4XX (-44) /* RCPT gave 4xx error */
#define ERRNO_MAIL4XX (-45) /* MAIL gave 4xx error */ #define ERRNO_MAIL4XX (-45) /* MAIL gave 4xx error */
#define ERRNO_DATA4XX (-46) /* DATA gave 4xx error */ #define ERRNO_DATA4XX (-46) /* DATA gave 4xx error */
#define ERRNO_PROXYFAIL (-47) /* Negotiation failed for proxy configured host */ #define ERRNO_PROXYFAIL (-47) /* Negotiation failed for proxy configured host */
#define ERRNO_AUTHPROB (-48) /* Authenticator "other" failure */ #define ERRNO_AUTHPROB (-48) /* Authenticator "other" failure */
#ifdef SUPPORT_I18N #ifdef SUPPORT_I18N
# define ERRNO_UTF8_FWD (-49) /* target not supporting SMTPUTF8 */ # define ERRNO_UTF8_FWD (-49) /* target not supporting SMTPUTF8 */
#endif #endif
#if defined(SUPPORT_TLS) && defined(EXPERIMENTAL_REQUIRETLS)
# define ERRNO_REQUIRETLS (-50) /* REQUIRETLS session not started */
#endif
/* These must be last, so all retry deferments can easily be identified */ /* These must be last, so all retry deferments can easily be identified */
#define ERRNO_RETRY_BASE (-51) /* Base to test against */ #define ERRNO_RETRY_BASE (-51) /* Base to test against */
#define ERRNO_RRETRY (-51) /* Not time for routing */ #define ERRNO_RRETRY (-51) /* Not time for routing */
#define ERRNO_WARN_BASE (-52) /* Base to test against */
#define ERRNO_LRETRY (-52) /* Not time for local delivery */ #define ERRNO_LRETRY (-52) /* Not time for local delivery */
#define ERRNO_HRETRY (-53) /* Not time for any remote host */ #define ERRNO_HRETRY (-53) /* Not time for any remote host */
#define ERRNO_LOCAL_ONLY (-54) /* Local-only delivery */ #define ERRNO_LOCAL_ONLY (-54) /* Local-only delivery */
#define ERRNO_QUEUE_DOMAIN (-55) /* Domain in queue_domains */ #define ERRNO_QUEUE_DOMAIN (-55) /* Domain in queue_domains */
#define ERRNO_TRETRY (-56) /* Transport concurrency limit */ #define ERRNO_TRETRY (-56) /* Transport concurrency limit */
/* Special actions to take after failure or deferment. */ /* Special actions to take after failure or deferment. */
enum { enum {
SPECIAL_NONE, /* No special action */ SPECIAL_NONE, /* No special action */
skipping to change at line 994 skipping to change at line 1004
#define SEARCH_STAR 0x01 #define SEARCH_STAR 0x01
#define SEARCH_STARAT 0x02 #define SEARCH_STARAT 0x02
/* Filter types */ /* Filter types */
enum { FILTER_UNSET, FILTER_FORWARD, FILTER_EXIM, FILTER_SIEVE }; enum { FILTER_UNSET, FILTER_FORWARD, FILTER_EXIM, FILTER_SIEVE };
/* Codes for ESMTP facilities offered by peer */ /* Codes for ESMTP facilities offered by peer */
#define OPTION_TLS BIT(0) #define OPTION_TLS BIT(0)
#define OPTION_IGNQ BIT(1) #define OPTION_IGNQ BIT(1)
#define OPTION_PRDR BIT(2) #define OPTION_PRDR BIT(2)
#define OPTION_UTF8 BIT(3) #define OPTION_UTF8 BIT(3)
#define OPTION_DSN BIT(4) #define OPTION_DSN BIT(4)
#define OPTION_PIPE BIT(5) #define OPTION_PIPE BIT(5)
#define OPTION_SIZE BIT(6) #define OPTION_SIZE BIT(6)
#define OPTION_CHUNKING BIT(7) #define OPTION_CHUNKING BIT(7)
#define OPTION_REQUIRETLS BIT(8)
#define OPTION_EARLY_PIPE BIT(9)
/* Codes for tls_requiretls requests (usually by sender) */
#define REQUIRETLS_MSG BIT(0) /* REQUIRETLS onward use */
/* Argument for *_getc */ /* Argument for *_getc */
#define GETC_BUFFER_UNLIMITED UINT_MAX #define GETC_BUFFER_UNLIMITED UINT_MAX
/* UTF-8 chars for line-drawing */ /* UTF-8 chars for line-drawing */
#define UTF8_DOWN_RIGHT "\xE2\x94\x8c" #define UTF8_DOWN_RIGHT "\xE2\x94\x8c"
#define UTF8_HORIZ "\xE2\x94\x80" #define UTF8_HORIZ "\xE2\x94\x80"
#define UTF8_VERT_RIGHT "\xE2\x94\x9C" #define UTF8_VERT_RIGHT "\xE2\x94\x9C"
#define UTF8_UP_RIGHT "\xE2\x94\x94" #define UTF8_UP_RIGHT "\xE2\x94\x94"
#define UTF8_VERT_2DASH "\xE2\x95\x8E" #define UTF8_VERT_2DASH "\xE2\x95\x8E"
/* Options on tls_close */ /* Options on tls_close */
#define TLS_NO_SHUTDOWN 0 #define TLS_NO_SHUTDOWN 0
#define TLS_SHUTDOWN_NOWAIT 1 #define TLS_SHUTDOWN_NOWAIT 1
#define TLS_SHUTDOWN_WAIT 2 #define TLS_SHUTDOWN_WAIT 2
#ifdef COMPILE_UTILITY
# define ALARM(seconds) alarm(seconds);
# define ALARM_CLR(seconds) alarm(seconds);
#else
/* For debugging of odd alarm-signal problems, stash caller info while the
alarm is active. Clear it down on cancelling the alarm so we can tell there
should not be one active. */
# define ALARM(seconds) \
debug_selector & D_any \
? (sigalarm_setter = CUS __FUNCTION__, alarm(seconds)) : alarm(seconds);
# define ALARM_CLR(seconds) \
debug_selector & D_any \
? (sigalarm_setter = NULL, alarm(seconds)) : alarm(seconds);
#endif
#define AUTHS_REGEX US"\\n250[\\s\\-]AUTH\\s+([\\-\\w \\t]+)(?:\\n|$)"
#define EARLY_PIPE_FEATURE_NAME "X_PIPE_CONNECT"
#define EARLY_PIPE_FEATURE_LEN 14
/* End of macros.h */ /* End of macros.h */
 End of changes. 11 change blocks. 
10 lines changed or deleted 47 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)