From 576ac4b8c9337cd5b0e12c2f827dd99c5ee6f25b Mon Sep 17 00:00:00 2001 From: Tom Lane Date: Tue, 5 Jul 2005 18:15:36 +0000 Subject: Fix initialization bug in pgcrypto openssl code. Marko Kreen --- contrib/pgcrypto/openssl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'contrib/pgcrypto/openssl.c') diff --git a/contrib/pgcrypto/openssl.c b/contrib/pgcrypto/openssl.c index 8a21194f8c..790f247988 100644 --- a/contrib/pgcrypto/openssl.c +++ b/contrib/pgcrypto/openssl.c @@ -26,7 +26,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $PostgreSQL: pgsql/contrib/pgcrypto/openssl.c,v 1.19 2005/07/04 02:02:01 momjian Exp $ + * $PostgreSQL: pgsql/contrib/pgcrypto/openssl.c,v 1.20 2005/07/05 18:15:36 tgl Exp $ */ #include @@ -393,7 +393,7 @@ ossl_des3_init(PX_Cipher * c, const uint8 *key, unsigned klen, const uint8 *iv) memset(&xkey1, 0, sizeof(xkey1)); memset(&xkey2, 0, sizeof(xkey2)); - memset(&xkey2, 0, sizeof(xkey2)); + memset(&xkey3, 0, sizeof(xkey3)); memcpy(&xkey1, key, klen > 8 ? 8 : klen); if (klen > 8) memcpy(&xkey2, key + 8, (klen - 8) > 8 ? 8 : (klen - 8)); -- cgit v1.2.3