ITS#8990 pickup SLAP_MOD_SOFT modops

This commit is contained in:
Howard Chu 2019-03-11 16:47:45 +00:00
parent c825edf67e
commit 4534528fe1

View File

@ -1591,6 +1591,7 @@ static int accesslog_response(Operation *op, SlapReply *rs) {
if ( m->sml_values ) {
i += m->sml_numvals;
} else if ( m->sml_op == LDAP_MOD_DELETE ||
m->sml_op == SLAP_MOD_SOFTDEL ||
m->sml_op == LDAP_MOD_REPLACE )
{
i++;
@ -1639,8 +1640,10 @@ static int accesslog_response(Operation *op, SlapReply *rs) {
char c_op;
switch ( m->sml_op ) {
case LDAP_MOD_ADD: c_op = '+'; break;
case LDAP_MOD_DELETE: c_op = '-'; break;
case LDAP_MOD_ADD: /* FALLTHRU */
case SLAP_MOD_SOFTADD: c_op = '+'; break;
case LDAP_MOD_DELETE: /* FALLTHRU */
case SLAP_MOD_SOFTDEL: c_op = '-'; break;
case LDAP_MOD_REPLACE: c_op = '='; break;
case LDAP_MOD_INCREMENT: c_op = '#'; break;
@ -1653,6 +1656,7 @@ static int accesslog_response(Operation *op, SlapReply *rs) {
accesslog_val2val( m->sml_desc, b, c_op, &vals[i] );
}
} else if ( m->sml_op == LDAP_MOD_DELETE ||
m->sml_op == SLAP_MOD_SOFTDEL ||
m->sml_op == LDAP_MOD_REPLACE )
{
vals[i].bv_len = m->sml_desc->ad_cname.bv_len + 2;
@ -1660,7 +1664,7 @@ static int accesslog_response(Operation *op, SlapReply *rs) {
ptr = lutil_strcopy( vals[i].bv_val,
m->sml_desc->ad_cname.bv_val );
*ptr++ = ':';
if ( m->sml_op == LDAP_MOD_DELETE ) {
if ( m->sml_op == LDAP_MOD_DELETE || m->sml_op == SLAP_MOD_SOFTDEL ) {
*ptr++ = '-';
} else {
*ptr++ = '=';