]> git.sur5r.net Git - openldap/commitdiff
Fix authmethod defaulting
authorKurt Zeilenga <kurt@openldap.org>
Sun, 16 Jul 2000 00:23:41 +0000 (00:23 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Sun, 16 Jul 2000 00:23:41 +0000 (00:23 +0000)
clients/tools/ldappasswd.c

index 91dd6fb53babbfdeec7c6db47120598436209680..d2e92702e9bd672ed9088bfd260fd07aee8b7abc 100644 (file)
@@ -257,6 +257,14 @@ main( int argc, char *argv[] )
                usage( argv[0] );
        } 
 
+       if (authmethod == -1) {
+#ifdef HAVE_CYRUS_SASL
+               authmethod = LDAP_AUTH_SASL;
+#else
+               authmethod = LDAP_AUTH_SIMPLE;
+#endif
+       }
+
        dn = strdup( argv[optind] );
 
        if( want_oldpw && oldpw == NULL ) {