]> git.sur5r.net Git - openldap/commitdiff
only abort update if failed pre/post read control is critical: the only thing RFC...
authorPierangelo Masarati <ando@openldap.org>
Sat, 14 Oct 2006 01:08:41 +0000 (01:08 +0000)
committerPierangelo Masarati <ando@openldap.org>
Sat, 14 Oct 2006 01:08:41 +0000 (01:08 +0000)
servers/slapd/back-bdb/add.c
servers/slapd/back-bdb/delete.c
servers/slapd/back-bdb/modify.c
servers/slapd/back-bdb/modrdn.c

index b66f19f6db0f36154bf0f5b0def3f8d6a2b68170..0e4959838a5984caf4a1a350a950202b9c947711 100644 (file)
@@ -395,7 +395,11 @@ retry:     /* transaction retry */
                        Debug( LDAP_DEBUG_TRACE,
                                "<=- " LDAP_XSTRING(bdb_add) ": post-read "
                                "failed!\n", 0, 0, 0 );
-                       goto return_results;
+                       if ( op->o_postread & SLAP_CONTROL_CRITICAL ) {
+                               /* FIXME: is it correct to abort
+                                * operation if control fails? */
+                               goto return_results;
+                       }
                }
        }
 
index 2e715f8050f7fb31d5ca8c5f6a0146947f40b082..64baaa48d923fdefb0273eeaaa569ab3d856c20c 100644 (file)
@@ -351,7 +351,11 @@ retry:     /* transaction retry */
                        Debug( LDAP_DEBUG_TRACE,
                                "<=- " LDAP_XSTRING(bdb_delete) ": pre-read "
                                "failed!\n", 0, 0, 0 );
-                       goto return_results;
+                       if ( op->o_preread & SLAP_CONTROL_CRITICAL ) {
+                               /* FIXME: is it correct to abort
+                                * operation if control fails? */
+                               goto return_results;
+                       }
                }
        }
 
index 76cf27bab87fa391d9f7203b777b1cf568eb6b08..a17948dfcf542e97218b92c533f610f61743debc 100644 (file)
@@ -499,9 +499,13 @@ retry:     /* transaction retry */
                        &slap_pre_read_bv, preread_ctrl ) )
                {
                        Debug( LDAP_DEBUG_TRACE,
-                               "<=- " LDAP_XSTRING(bdb_modify) ": pre-read failed!\n",
-                               0, 0, 0 );
-                       goto return_results;
+                               "<=- " LDAP_XSTRING(bdb_modify) ": pre-read "
+                               "failed!\n", 0, 0, 0 );
+                       if ( op->o_preread & SLAP_CONTROL_CRITICAL ) {
+                               /* FIXME: is it correct to abort
+                                * operation if control fails? */
+                               goto return_results;
+                       }
                }
        }
 
@@ -570,7 +574,11 @@ retry:     /* transaction retry */
                        Debug( LDAP_DEBUG_TRACE,
                                "<=- " LDAP_XSTRING(bdb_modify)
                                ": post-read failed!\n", 0, 0, 0 );
-                       goto return_results;
+                       if ( op->o_postread & SLAP_CONTROL_CRITICAL ) {
+                               /* FIXME: is it correct to abort
+                                * operation if control fails? */
+                               goto return_results;
+                       }
                }
        }
 
index 6aececa31ef7629efc7df70c16b199213875c43f..4ea518e90011d558acf74f266e21538e3e4f3d4a 100644 (file)
@@ -578,8 +578,12 @@ retry:     /* transaction retry */
                {
                        Debug( LDAP_DEBUG_TRACE,        
                                "<=- " LDAP_XSTRING(bdb_modrdn)
-                               ": post-read failed!\n", 0, 0, 0 );
-                       goto return_results;
+                               ": pre-read failed!\n", 0, 0, 0 );
+                       if ( op->o_preread & SLAP_CONTROL_CRITICAL ) {
+                               /* FIXME: is it correct to abort
+                                * operation if control fails? */
+                               goto return_results;
+                       }
                }                   
        }
 
@@ -717,7 +721,11 @@ retry:     /* transaction retry */
                        Debug( LDAP_DEBUG_TRACE,        
                                "<=- " LDAP_XSTRING(bdb_modrdn)
                                ": post-read failed!\n", 0, 0, 0 );
-                       goto return_results;
+                       if ( op->o_postread & SLAP_CONTROL_CRITICAL ) {
+                               /* FIXME: is it correct to abort
+                                * operation if control fails? */
+                               goto return_results;
+                       }
                }                   
        }