aboutsummaryrefslogtreecommitdiffstats
path: root/ssl/ssl_sess.c
diff options
context:
space:
mode:
authorBodo Möller <bodo@openssl.org>1999-05-13 15:09:38 +0000
committerBodo Möller <bodo@openssl.org>1999-05-13 15:09:38 +0000
commitb56bce4fc72c99c1ac85ee7de4d0145fe026bb4e (patch)
tree40c085c04a84e670495414815d376182b5dfaae2 /ssl/ssl_sess.c
parent0981259adab3fa083bff0838fb64bcf68f687e1b (diff)
downloadopenssl-b56bce4fc72c99c1ac85ee7de4d0145fe026bb4e.tar.gz
New structure type SESS_CERT used instead of CERT inside SSL_SESSION.
While modifying the sources, I found some inconsistencies on the use of s->cert vs. s->session->sess_cert; I don't know if those could really have caused problems, but possibly this is a proper bug-fix and not just a clean-up.
Diffstat (limited to 'ssl/ssl_sess.c')
-rw-r--r--ssl/ssl_sess.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/ssl/ssl_sess.c b/ssl/ssl_sess.c
index 88d4b50c75..259725c7a1 100644
--- a/ssl/ssl_sess.c
+++ b/ssl/ssl_sess.c
@@ -115,6 +115,8 @@ SSL_SESSION *SSL_SESSION_new(void)
int ssl_get_new_session(SSL *s, int session)
{
+ /* This gets used by clients and servers. */
+
SSL_SESSION *ss=NULL;
if ((ss=SSL_SESSION_new()) == NULL) return(0);
@@ -183,6 +185,8 @@ int ssl_get_new_session(SSL *s, int session)
int ssl_get_prev_session(SSL *s, unsigned char *session_id, int len)
{
+ /* This is used only by servers. */
+
SSL_SESSION *ret=NULL,data;
int copy=1;
@@ -377,7 +381,7 @@ void SSL_SESSION_free(SSL_SESSION *ss)
memset(ss->key_arg,0,SSL_MAX_KEY_ARG_LENGTH);
memset(ss->master_key,0,SSL_MAX_MASTER_KEY_LENGTH);
memset(ss->session_id,0,SSL_MAX_SSL_SESSION_ID_LENGTH);
- if (ss->sess_cert != NULL) ssl_cert_free(ss->sess_cert);
+ if (ss->sess_cert != NULL) ssl_sess_cert_free(ss->sess_cert);
if (ss->peer != NULL) X509_free(ss->peer);
if (ss->ciphers != NULL) sk_SSL_CIPHER_free(ss->ciphers);
memset(ss,0,sizeof(*ss));