Fall back from --bind-dynamic to --bind-interfaces in BSD, rather than quitting.

This commit is contained in:
Simon Kelley
2012-06-26 16:55:23 +01:00
parent 39f1b8e73d
commit 2b5bae9a8f
3 changed files with 17 additions and 3 deletions

View File

@@ -114,11 +114,16 @@ int main (int argc, char **argv)
set_option_bool(OPT_NOWILD);
}
# endif
/* -- bind-dynamic not supported on !Linux, fall back to --bind-interfaces */
if (option_bool(OPT_CLEVERBIND))
die(_("--bind-dynamic not available on this platform"), NULL, EC_BADCONF);
{
bind_fallback = 1;
set_option_bool(OPT_NOWILD);
reset_option_bool(OPT_CLVERBIND);
}
#endif
#ifndef HAVE_TFTP
if (daemon->tftp_unlimited || daemon->tftp_interfaces)
die(_("TFTP server not available: set HAVE_TFTP in src/config.h"), NULL, EC_BADCONF);