]> git.sur5r.net Git - openldap/commitdiff
re-fix cast and logic
authorPierangelo Masarati <ando@openldap.org>
Mon, 14 Nov 2005 15:02:14 +0000 (15:02 +0000)
committerPierangelo Masarati <ando@openldap.org>
Mon, 14 Nov 2005 15:02:14 +0000 (15:02 +0000)
servers/slapd/overlays/valsort.c

index 2ea7c44c496c50ba5b03ea1b254731fcdae8f2ee..1fe209b3c7b4349ce987854a06133415f907692d 100644 (file)
@@ -339,8 +339,9 @@ valsort_response( Operation *op, SlapReply *rs )
 
                                if ( a->a_vals != a->a_nvals ) {
                                        ptr = a->a_vals[i].bv_val;
-                                       end = (char *) ber_bvchr( &a->a_vals[i], '}' ) + 1;
+                                       end = ber_bvchr( &a->a_vals[i], '}' );
                                        assert( end != NULL );
+                                       end++;
                                        for (;*end;)
                                                *ptr++ = *end++;
                                        *ptr = '\0';