]> git.sur5r.net Git - openldap/commitdiff
Fix off-by-one pointer error. Garbage byte between uuid and csn in slog_entry.
authorHallvard Furuseth <hallvard@openldap.org>
Tue, 2 Aug 2005 08:43:27 +0000 (08:43 +0000)
committerHallvard Furuseth <hallvard@openldap.org>
Tue, 2 Aug 2005 08:43:27 +0000 (08:43 +0000)
servers/slapd/overlays/syncprov.c

index 5a075cd1adead3f752b382fce9c97041da266057..b57a5a46bef164665b12cba37c5bd1bf9213aabe 100644 (file)
@@ -1180,10 +1180,10 @@ syncprov_add_slog( Operation *op, struct berval *csn )
                se->se_tag = op->o_tag;
 
                se->se_uuid.bv_val = (char *)(se+1);
-               se->se_csn.bv_val = se->se_uuid.bv_val + opc->suuid.bv_len + 1;
                AC_MEMCPY( se->se_uuid.bv_val, opc->suuid.bv_val, opc->suuid.bv_len );
                se->se_uuid.bv_len = opc->suuid.bv_len;
 
+               se->se_csn.bv_val = se->se_uuid.bv_val + opc->suuid.bv_len;
                AC_MEMCPY( se->se_csn.bv_val, csn->bv_val, csn->bv_len );
                se->se_csn.bv_val[csn->bv_len] = '\0';
                se->se_csn.bv_len = csn->bv_len;