]> git.sur5r.net Git - openldap/commitdiff
ITS#4966 valsort_modify: ignore Delete modops with no values
authorHoward Chu <hyc@openldap.org>
Fri, 25 May 2007 00:58:59 +0000 (00:58 +0000)
committerHoward Chu <hyc@openldap.org>
Fri, 25 May 2007 00:58:59 +0000 (00:58 +0000)
servers/slapd/overlays/valsort.c

index f1b82e917c763e4afea0057c7452e6b00ab27b36..c7a7dfa5d5b36081fe5794763a46c4e8a56019ed 100644 (file)
@@ -447,6 +447,9 @@ valsort_modify( Operation *op, SlapReply *rs )
                if ( !(vi->vi_sort & VALSORT_WEIGHTED ))
                        continue;
                for (ml = op->orm_modlist; ml; ml=ml->sml_next ) {
+                       /* Must be a Delete Attr op, so no values to consider */
+                       if ( !ml->sml_values )
+                               continue;
                        if ( ml->sml_desc == vi->vi_ad )
                                break;
                }