]> git.sur5r.net Git - openldap/blobdiff - servers/slapd/value.c
removing global overlays should work now as well
[openldap] / servers / slapd / value.c
index ad7be0f46665e1cdec6756c0770fca1dcfbce9d9..48be7682faac358b07d88e7c89386ed445474062 100644 (file)
@@ -2,7 +2,7 @@
 /* $OpenLDAP$ */
 /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
  *
- * Copyright 1998-2008 The OpenLDAP Foundation.
+ * Copyright 1998-2011 The OpenLDAP Foundation.
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -469,7 +469,7 @@ ordered_value_pretty(
        struct berval *out,
        void *ctx )
 {
-       struct berval   bv = *val,
+       struct berval   bv,
                        idx = BER_BVNULL;
        int             rc;
 
@@ -478,6 +478,8 @@ ordered_value_pretty(
        assert( val != NULL );
        assert( out != NULL );
 
+       bv = *val;
+
        if ( ad->ad_type->sat_flags & SLAP_AT_ORDERED ) {
 
                /* Skip past the assertion index */
@@ -538,7 +540,7 @@ ordered_value_normalize(
        struct berval *normalized,
        void *ctx )
 {
-       struct berval   bv = *val,
+       struct berval   bv,
                        idx = BER_BVNULL;
        int             rc;
 
@@ -547,6 +549,8 @@ ordered_value_normalize(
        assert( val != NULL );
        assert( normalized != NULL );
 
+       bv = *val;
+
        if ( ad->ad_type->sat_flags & SLAP_AT_ORDERED ) {
 
                /* Skip past the assertion index */