From 1fba3a5c13ea4aee3de3af606fc0f2425a5c013c Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Fri, 8 Feb 2002 21:53:04 +0000 Subject: [PATCH] Fix flag initialization --- libraries/libldap/dntest.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libraries/libldap/dntest.c b/libraries/libldap/dntest.c index d3610d73c9..caa03212c9 100644 --- a/libraries/libldap/dntest.c +++ b/libraries/libldap/dntest.c @@ -31,7 +31,7 @@ int main( int argc, char *argv[] ) { int rc, i, debug = 0, f2 = 0; - unsigned flags[ 2 ] = { 0U, LDAP_DN_FORMAT_LDAPV3 }; + unsigned flags[ 2 ] = { 0U, 0 }; char *strin, *str = NULL, buf[ 1024 ]; LDAPDN *dn, *dn2 = NULL; @@ -114,6 +114,9 @@ main( int argc, char *argv[] ) } } + if ( flags[ 1 ] == 0 ) + flags[ 1 ] = LDAP_DN_FORMAT_LDAPV3; + f2 = 1; rc = ldap_str2dn( strin, &dn, flags[ 0 ] ); -- 2.39.5