*************************************************/
/* Copyright (c) University of Cambridge 1995 - 2018 */
+/* Copyright (c) The Exim Maintainers 2020 - 2021 */
/* See the file NOTICE for conditions of use and distribution. */
optionlist manualroute_router_options[] = {
{ "host_all_ignored", opt_stringptr,
- (void *)(offsetof(manualroute_router_options_block, host_all_ignored)) },
+ OPT_OFF(manualroute_router_options_block, host_all_ignored) },
{ "host_find_failed", opt_stringptr,
- (void *)(offsetof(manualroute_router_options_block, host_find_failed)) },
+ OPT_OFF(manualroute_router_options_block, host_find_failed) },
{ "hosts_randomize", opt_bool,
- (void *)(offsetof(manualroute_router_options_block, hosts_randomize)) },
+ OPT_OFF(manualroute_router_options_block, hosts_randomize) },
{ "route_data", opt_stringptr,
- (void *)(offsetof(manualroute_router_options_block, route_data)) },
+ OPT_OFF(manualroute_router_options_block, route_data) },
{ "route_list", opt_stringptr,
- (void *)(offsetof(manualroute_router_options_block, route_list)) },
+ OPT_OFF(manualroute_router_options_block, route_list) },
{ "same_domain_copy_routing", opt_bool|opt_public,
- (void *)(offsetof(router_instance, same_domain_copy_routing)) }
+ OPT_OFF(router_instance, same_domain_copy_routing) }
};
/* Size of the options list. An extern variable has to be used so that its
BOOL individual_transport_set = FALSE;
BOOL randomize = ob->hosts_randomize;
-addr_new = addr_new; /* Keep picky compilers happy */
-addr_succeed = addr_succeed;
-
DEBUG(D_route) debug_printf("%s router called for %s\n domain = %s\n",
rblock->name, addr->address, addr->domain);
int sep = -(';'); /* Default is semicolon */
listptr = ob->route_list;
- while ((route_item = string_nextinlist(&listptr, &sep, NULL, 0)) != NULL)
+ while ((route_item = string_nextinlist(&listptr, &sep, NULL, 0)))
{
int rc;
defined for these hosts. It will be a remote one, as a local transport is
dealt with above. However, we don't need one if verifying only. */
-if (transport == NULL && verify == v_none)
+if (!transport && verify == v_none)
{
log_write(0, LOG_MAIN, "Error in %s router: no transport defined",
rblock->name);