From: jsing Date: Fri, 14 Apr 2017 15:20:16 +0000 (+0000) Subject: Switch i2d_SSL_SESSION() back to freezero(3) now that the size constraints X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=c9ce0707c14790a14b81231caa471d0e5ee273d0;p=openbsd Switch i2d_SSL_SESSION() back to freezero(3) now that the size constraints have been relaxed. --- diff --git a/lib/libssl/ssl_asn1.c b/lib/libssl/ssl_asn1.c index aca34f8c3ea..8e6528d1530 100644 --- a/lib/libssl/ssl_asn1.c +++ b/lib/libssl/ssl_asn1.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ssl_asn1.c,v 1.51 2017/04/11 13:14:08 jsing Exp $ */ +/* $OpenBSD: ssl_asn1.c,v 1.52 2017/04/14 15:20:16 jsing Exp $ */ /* * Copyright (c) 2016 Joel Sing @@ -205,12 +205,9 @@ i2d_SSL_SESSION(SSL_SESSION *s, unsigned char **pp) rv = (int)data_len; err: - if (data != NULL) - explicit_bzero(data, data_len); - CBB_cleanup(&session); + freezero(data, data_len); free(peer_cert_bytes); - free(data); return rv; }