From b1faecd35cf4106eed96dea74e642c8c4570364c Mon Sep 17 00:00:00 2001 From: Pierangelo Masarati Date: Sat, 5 Aug 2006 15:51:13 +0000 Subject: [PATCH] process callbacks first; they are supposed to remove modifications they successfully handled, so that regular modify function can complain if any unhandled modification remains --- servers/slapd/back-monitor/entry.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/servers/slapd/back-monitor/entry.c b/servers/slapd/back-monitor/entry.c index a7b83d489f..3a2377489b 100644 --- a/servers/slapd/back-monitor/entry.c +++ b/servers/slapd/back-monitor/entry.c @@ -42,11 +42,7 @@ monitor_entry_update( mp = ( monitor_entry_t * )e->e_private; - if ( mp->mp_info && mp->mp_info->mss_update ) { - rc = mp->mp_info->mss_update( op, rs, e ); - } - - if ( rc == SLAP_CB_CONTINUE && mp->mp_cb ) { + if ( mp->mp_cb ) { struct monitor_callback_t *mc; for ( mc = mp->mp_cb; mc; mc = mc->mc_next ) { @@ -59,6 +55,10 @@ monitor_entry_update( } } + if ( rc == SLAP_CB_CONTINUE && mp->mp_info && mp->mp_info->mss_update ) { + rc = mp->mp_info->mss_update( op, rs, e ); + } + if ( rc == SLAP_CB_CONTINUE ) { rc = LDAP_SUCCESS; } @@ -115,11 +115,7 @@ monitor_entry_modify( mp = ( monitor_entry_t * )e->e_private; - if ( mp->mp_info && mp->mp_info->mss_modify ) { - rc = mp->mp_info->mss_modify( op, rs, e ); - } - - if ( rc == SLAP_CB_CONTINUE && mp->mp_cb ) { + if ( mp->mp_cb ) { struct monitor_callback_t *mc; for ( mc = mp->mp_cb; mc; mc = mc->mc_next ) { @@ -132,6 +128,10 @@ monitor_entry_modify( } } + if ( rc == SLAP_CB_CONTINUE && mp->mp_info && mp->mp_info->mss_modify ) { + rc = mp->mp_info->mss_modify( op, rs, e ); + } + if ( rc == SLAP_CB_CONTINUE ) { rc = LDAP_SUCCESS; } -- 2.39.5