mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-01-30 13:30:57 +08:00
ITS#4600 #if out redundant checks. will delete them later.
This commit is contained in:
parent
17296f11e7
commit
574769395a
@ -315,7 +315,7 @@ fe_op_add( Operation *op, SlapReply *rs )
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* check for duplicate values */
|
/* check for unmodifiable attributes */
|
||||||
rs->sr_err = slap_mods_no_repl_user_mod_check( op,
|
rs->sr_err = slap_mods_no_repl_user_mod_check( op,
|
||||||
op->ora_modlist, &rs->sr_text, textbuf, textlen );
|
op->ora_modlist, &rs->sr_text, textbuf, textlen );
|
||||||
if ( rs->sr_err != LDAP_SUCCESS ) {
|
if ( rs->sr_err != LDAP_SUCCESS ) {
|
||||||
@ -323,12 +323,14 @@ fe_op_add( Operation *op, SlapReply *rs )
|
|||||||
goto done;
|
goto done;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if 0 /* This is a no-op since *modtail is NULL */
|
||||||
rs->sr_err = slap_mods2entry( *modtail, &op->ora_e,
|
rs->sr_err = slap_mods2entry( *modtail, &op->ora_e,
|
||||||
0, 0, &rs->sr_text, textbuf, textlen );
|
0, 0, &rs->sr_text, textbuf, textlen );
|
||||||
if ( rs->sr_err != LDAP_SUCCESS ) {
|
if ( rs->sr_err != LDAP_SUCCESS ) {
|
||||||
send_ldap_result( op, rs );
|
send_ldap_result( op, rs );
|
||||||
goto done;
|
goto done;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
cb.sc_next = op->o_callback;
|
cb.sc_next = op->o_callback;
|
||||||
op->o_callback = &cb;
|
op->o_callback = &cb;
|
||||||
@ -431,7 +433,7 @@ slap_mods2entry(
|
|||||||
attr->a_vals = ch_realloc( attr->a_vals,
|
attr->a_vals = ch_realloc( attr->a_vals,
|
||||||
sizeof( struct berval ) * (i+j) );
|
sizeof( struct berval ) * (i+j) );
|
||||||
|
|
||||||
/* should check for duplicates */
|
/* checked for duplicates in slap_mods_check */
|
||||||
|
|
||||||
if ( dup ) {
|
if ( dup ) {
|
||||||
for ( j = 0; mods->sml_values[j].bv_val; j++ ) {
|
for ( j = 0; mods->sml_values[j].bv_val; j++ ) {
|
||||||
@ -470,6 +472,7 @@ slap_mods2entry(
|
|||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if 0 /* checked for duplicates in slap_mods_check */
|
||||||
if( mods->sml_values[1].bv_val != NULL ) {
|
if( mods->sml_values[1].bv_val != NULL ) {
|
||||||
/* check for duplicates */
|
/* check for duplicates */
|
||||||
int i, j, rc, match;
|
int i, j, rc, match;
|
||||||
@ -505,11 +508,11 @@ slap_mods2entry(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
attr = attr_alloc( mods->sml_desc );
|
attr = attr_alloc( mods->sml_desc );
|
||||||
|
|
||||||
/* move values to attr structure */
|
/* move values to attr structure */
|
||||||
/* should check for duplicates */
|
|
||||||
if ( dup ) {
|
if ( dup ) {
|
||||||
int i;
|
int i;
|
||||||
for ( i = 0; mods->sml_values[i].bv_val; i++ ) /* EMPTY */;
|
for ( i = 0; mods->sml_values[i].bv_val; i++ ) /* EMPTY */;
|
||||||
|
Loading…
Reference in New Issue
Block a user