]> git.sur5r.net Git - openldap/commitdiff
Silence valgrind warnings of uninit'd memory
authorHoward Chu <hyc@openldap.org>
Wed, 24 Sep 2003 03:03:53 +0000 (03:03 +0000)
committerHoward Chu <hyc@openldap.org>
Wed, 24 Sep 2003 03:03:53 +0000 (03:03 +0000)
servers/slapd/back-bdb/add.c
servers/slapd/back-bdb/modrdn.c

index 67b04cc6d51a4e94dabe4d0d28bacfd7dd937d70..14fa8bd4778ccf0bd967339237fd177b82393ec2 100644 (file)
@@ -506,6 +506,7 @@ retry:      /* transaction retry */
        } else {
                char gid[DB_XIDDATASIZE];
 
+               memset( gid, 0, sizeof(gid) );
                snprintf( gid, sizeof( gid ), "%s-%08lx-%08lx",
                        bdb_uuid.bv_val, (long) op->o_connid, (long) op->o_opid );
 
index 93150525f7a9d2f4fd6c620c2c134289b9cc8b38..ba0502f2072af5082c73dd97792f4d94d61cb217 100644 (file)
@@ -960,6 +960,7 @@ retry:      /* transaction retry */
        } else {
                char gid[DB_XIDDATASIZE];
 
+               memset( gid, 0, sizeof(gid) );
                snprintf( gid, sizeof( gid ), "%s-%08lx-%08lx",
                        bdb_uuid.bv_val, (long) op->o_connid, (long) op->o_opid );