]> git.sur5r.net Git - openldap/commitdiff
Warning cleanup: signed meets unsigned. ber_flatten2() returns -1 on
authorHallvard Furuseth <hallvard@openldap.org>
Mon, 13 Oct 2008 08:44:54 +0000 (08:44 +0000)
committerHallvard Furuseth <hallvard@openldap.org>
Mon, 13 Oct 2008 08:44:54 +0000 (08:44 +0000)
error, not LBER_ERROR.

libraries/libldap/abandon.c
libraries/libldap/ldap_sync.c
libraries/libldap/request.c

index 8f2fb3419499583f22babc83938cba956afc923e..bd9ebb38181a3e0907d90c6d11de6b9bce924725 100644 (file)
@@ -447,8 +447,7 @@ int
 ldap_int_bisect_delete( ber_int_t **vp, ber_len_t *np, int id, int idx )
 {
        ber_int_t       *v;
-       ber_len_t       n;
-       int             i;
+       ber_len_t       i, n;
 
        assert( vp != NULL );
        assert( np != NULL );
index 6e7cd48084d7fde51d4459f1d440d744447c3e93..da699ff3ee99776e02175ad598f7473a5732664e 100644 (file)
@@ -691,7 +691,7 @@ ldap_sync_init( ldap_sync_t *ls, int mode )
                rc ? "!!! " : "",
                rc );
 #endif /* LDAP_SYNC_TRACE */
-       if ( rc == LBER_ERROR ) {
+       if ( rc < 0 ) {
                rc = LDAP_OTHER;
                 goto done;
         }
index 80304118869b0b64cfff412960bf7d2226082b15..e6b695a6442e6260c2cf22632fcf481b310264b5 100644 (file)
@@ -1099,7 +1099,7 @@ ldap_chase_v3referrals( LDAP *ld, LDAPRequest *lr, char **refs, int sref, char *
                        /* See if we've already requested this DN with this conn */
                        LDAPRequest *lp;
                        int looped = 0;
-                       int len = srv->lud_dn ? strlen( srv->lud_dn ) : 0;
+                       ber_len_t len = srv->lud_dn ? strlen( srv->lud_dn ) : 0;
                        for ( lp = origreq; lp; ) {
                                if ( lp->lr_conn == lc
                                        && len == lp->lr_dn.bv_len
@@ -1358,7 +1358,7 @@ ldap_chase_referrals( LDAP *ld,
                if (( lc = find_connection( ld, srv, 1 )) != NULL ) {
                        LDAPRequest *lp;
                        int looped = 0;
-                       int len = srv->lud_dn ? strlen( srv->lud_dn ) : 0;
+                       ber_len_t len = srv->lud_dn ? strlen( srv->lud_dn ) : 0;
                        for ( lp = lr; lp; lp = lp->lr_parent ) {
                                if ( lp->lr_conn == lc
                                        && len == lp->lr_dn.bv_len )