/* Copyright (c) University of Cambridge 1995 - 2018 */
/* See the file NOTICE for conditions of use and distribution. */
/* Copyright (c) University of Cambridge 1995 - 2018 */
/* See the file NOTICE for conditions of use and distribution. */
optionlist manualroute_router_options[] = {
{ "host_all_ignored", opt_stringptr,
optionlist manualroute_router_options[] = {
{ "host_all_ignored", opt_stringptr,
if (Ustrcmp(ob->host_find_failed, hff_names[i]) == 0)
{
ob->hff_code = hff_codes[i];
break;
}
if (Ustrcmp(ob->host_find_failed, hff_names[i]) == 0)
{
ob->hff_code = hff_codes[i];
break;
}
if (ob->hff_code < 0)
log_write(0, LOG_PANIC_DIE|LOG_CONFIG_FOR, "%s router:\n "
"unrecognized setting for host_find_failed option", rblock->name);
if (ob->hff_code < 0)
log_write(0, LOG_PANIC_DIE|LOG_CONFIG_FOR, "%s router:\n "
"unrecognized setting for host_find_failed option", rblock->name);
if (Ustrcmp(ob->host_all_ignored, hff_names[i]) == 0)
{
ob->hai_code = hff_codes[i];
break;
}
if (Ustrcmp(ob->host_all_ignored, hff_names[i]) == 0)
{
ob->hai_code = hff_codes[i];
break;
}
if (ob->hai_code < 0)
log_write(0, LOG_PANIC_DIE|LOG_CONFIG_FOR, "%s router:\n "
"unrecognized setting for host_all_ignored option", rblock->name);
/* One of route_list or route_data must be specified */
if (ob->hai_code < 0)
log_write(0, LOG_PANIC_DIE|LOG_CONFIG_FOR, "%s router:\n "
"unrecognized setting for host_all_ignored option", rblock->name);
/* One of route_list or route_data must be specified */
log_write(0, LOG_PANIC_DIE|LOG_CONFIG_FOR, "%s router:\n "
"route_list or route_data (but not both) must be specified",
rblock->name);
log_write(0, LOG_PANIC_DIE|LOG_CONFIG_FOR, "%s router:\n "
"route_list or route_data (but not both) must be specified",
rblock->name);
DEBUG(D_route) debug_printf("%s router called for %s\n domain = %s\n",
rblock->name, addr->address, addr->domain);
DEBUG(D_route) debug_printf("%s router called for %s\n domain = %s\n",
rblock->name, addr->address, addr->domain);
- while ((route_item = string_nextinlist(&listptr, &sep, NULL, 0)) != NULL)
+ while ((route_item = string_nextinlist(&listptr, &sep, NULL, 0)))
if (!(route_item = rf_expand_data(addr, ob->route_data, &rc)))
return rc;
(void) parse_route_item(route_item, NULL, &hostlist, &options);
if (!(route_item = rf_expand_data(addr, ob->route_data, &rc)))
return rc;
(void) parse_route_item(route_item, NULL, &hostlist, &options);
rc = rf_get_errors_address(addr, rblock, verify, &addr->prop.errors_address);
if (rc != OK) return rc;
rc = rf_get_errors_address(addr, rblock, verify, &addr->prop.errors_address);
if (rc != OK) return rc;
rc = rf_get_munge_headers(addr, rblock, &addr->prop.extra_headers,
&addr->prop.remove_headers);
rc = rf_get_munge_headers(addr, rblock, &addr->prop.extra_headers,
&addr->prop.remove_headers);
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. */
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. */
{
log_write(0, LOG_MAIN, "Error in %s router: no transport defined",
rblock->name);
{
log_write(0, LOG_MAIN, "Error in %s router: no transport defined",
rblock->name);