From: Rein Tollevik Date: Thu, 30 Dec 2010 19:45:08 +0000 (+0000) Subject: ITS#6754: Fail if there are unrecognized command-line arguments. X-Git-Tag: MIGRATION_CVS2GIT~321 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=a1a5affeb00f79213af6fb3e75ec8450330e8681;p=openldap ITS#6754: Fail if there are unrecognized command-line arguments. --- diff --git a/servers/slapd/main.c b/servers/slapd/main.c index 06ebfde46c..d04e1ef4d9 100644 --- a/servers/slapd/main.c +++ b/servers/slapd/main.c @@ -683,6 +683,9 @@ unhandled_option:; } } + if ( optind != argc ) + goto unhandled_option; + ber_set_option(NULL, LBER_OPT_DEBUG_LEVEL, &slap_debug); ldap_set_option(NULL, LDAP_OPT_DEBUG_LEVEL, &slap_debug); ldif_debug = slap_debug;