Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/boringssl.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Benjamin <davidben@chromium.org>2014-08-27 23:25:21 +0400
committerAdam Langley <agl@google.com>2014-08-28 04:42:20 +0400
commit041b58a6684d2f032f66fa45b0e35f50f9a0fa40 (patch)
treea06b61896cbf84ed19b43809719b6c1a74fb48c5 /ssl/ssl_lib.c
parent457112e1973251a721ae419128d7108844d3c1a3 (diff)
Remove session_ctx macro.
Don't pollute the embedder's namespace with a session_ctx macro. It looks like the difference was that, without TLS extensions, session_ctx was ctx rather than initial_ctx. Now it's always initial_ctx. Retain the semantics of switching SSL_CTX's out after the fact, until/unless we decide to replace that with something less scary-sounding. Change-Id: Ie5df5138aec25218ca80031cf645671968b8a54a Reviewed-on: https://boringssl-review.googlesource.com/1663 Reviewed-by: Adam Langley <agl@google.com>
Diffstat (limited to 'ssl/ssl_lib.c')
-rw-r--r--ssl/ssl_lib.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c
index d6f6bdc2..01d59c47 100644
--- a/ssl/ssl_lib.c
+++ b/ssl/ssl_lib.c
@@ -2344,14 +2344,14 @@ void ssl_update_cache(SSL *s,int mode)
* and it would be rather hard to do anyway :-) */
if (s->session->session_id_length == 0) return;
- i=s->session_ctx->session_cache_mode;
+ i=s->initial_ctx->session_cache_mode;
if ((i & mode) && (!s->hit)
&& ((i & SSL_SESS_CACHE_NO_INTERNAL_STORE)
- || SSL_CTX_add_session(s->session_ctx,s->session))
- && (s->session_ctx->new_session_cb != NULL))
+ || SSL_CTX_add_session(s->initial_ctx,s->session))
+ && (s->initial_ctx->new_session_cb != NULL))
{
CRYPTO_add(&s->session->references,1,CRYPTO_LOCK_SSL_SESSION);
- if (!s->session_ctx->new_session_cb(s,s->session))
+ if (!s->initial_ctx->new_session_cb(s,s->session))
SSL_SESSION_free(s->session);
}
@@ -2360,10 +2360,10 @@ void ssl_update_cache(SSL *s,int mode)
((i & mode) == mode))
{
if ( (((mode & SSL_SESS_CACHE_CLIENT)
- ?s->session_ctx->stats.sess_connect_good
- :s->session_ctx->stats.sess_accept_good) & 0xff) == 0xff)
+ ?s->initial_ctx->stats.sess_connect_good
+ :s->initial_ctx->stats.sess_accept_good) & 0xff) == 0xff)
{
- SSL_CTX_flush_sessions(s->session_ctx,(unsigned long)time(NULL));
+ SSL_CTX_flush_sessions(s->initial_ctx,(unsigned long)time(NULL));
}
}
}