]> git.sur5r.net Git - openldap/blobdiff - libraries/libldap/controls.c
silence excessive logging
[openldap] / libraries / libldap / controls.c
index 9925357b0c2065a50d6764155424bd0f5b47eea2..12f455be9863cc1e9fc97ef205d6a2b14abc3bd5 100644 (file)
@@ -38,6 +38,7 @@ ldap_int_put_controls(
        LDAPControl *const *c;
 
        assert( ld != NULL );
+       assert( LDAP_VALID(ld) );
        assert( ber != NULL );
 
        if( ctrls == NULL ) {
@@ -413,9 +414,9 @@ ldap_create_control(
        LDAPControl *ctrl;
        struct berval *bvalp;
 
-       if ( requestOID == NULL || ctrlp == NULL ) {
-               return LDAP_PARAM_ERROR;
-       }
+       assert( requestOID != NULL );
+       assert( ber != NULL );
+       assert( ctrlp != NULL );
 
        ctrl = (LDAPControl *) LDAP_MALLOC( sizeof(LDAPControl) );
        if ( ctrl == NULL ) {
@@ -453,6 +454,7 @@ int ldap_int_client_controls( LDAP *ld, LDAPControl **ctrls )
        LDAPControl *const *c;
 
        assert( ld != NULL );
+       assert( LDAP_VALID(ld) );
 
        if( ctrls == NULL ) {
                /* use default server controls */