]> git.sur5r.net Git - openldap/commitdiff
Replace (int)LDAP_BOOL_GET(...) with LDAP_BOOL_GET(...)==LDAP_OPT_ON
authorHallvard Furuseth <hallvard@openldap.org>
Tue, 9 Mar 1999 07:42:17 +0000 (07:42 +0000)
committerHallvard Furuseth <hallvard@openldap.org>
Tue, 9 Mar 1999 07:42:17 +0000 (07:42 +0000)
libraries/libldap/options.c

index a4b5d8ae2b2bb043c25f6b76ba7589b2ca9ad714..3c99686ff37d4dec363012b233aad70fa4184e69 100644 (file)
@@ -127,15 +127,18 @@ ldap_get_option(
                return 0;
 
        case LDAP_OPT_REFERRALS:
-               * (int *) outvalue = (int) LDAP_BOOL_GET(lo, LDAP_BOOL_REFERRALS);
+               * (int *) outvalue = (LDAP_BOOL_GET(lo, LDAP_BOOL_REFERRALS) ==
+                                     LDAP_OPT_ON);
                return 0;
                
        case LDAP_OPT_RESTART:
-               * (int *) outvalue = (int) LDAP_BOOL_GET(lo, LDAP_BOOL_RESTART);
+               * (int *) outvalue = (LDAP_BOOL_GET(lo, LDAP_BOOL_RESTART) ==
+                                     LDAP_OPT_ON);
                return 0;
 
        case LDAP_OPT_DNS:      /* LDAPv2 */
-               * (int *) outvalue = (int) LDAP_BOOL_GET(lo, LDAP_BOOL_DNS);
+               * (int *) outvalue = (LDAP_BOOL_GET(lo, LDAP_BOOL_DNS) ==
+                                     LDAP_OPT_ON);
                return 0;
 
        case LDAP_OPT_PROTOCOL_VERSION: