]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Init session only if it doesn't exist
authorAlan T. DeKok <aland@freeradius.org>
Sun, 11 Oct 2015 18:34:45 +0000 (14:34 -0400)
committerAlan T. DeKok <aland@freeradius.org>
Sun, 11 Oct 2015 18:34:45 +0000 (14:34 -0400)
src/main/tls.c

index 8d40b204bdcaabe983132a3dccea43f05211c207..16eef6fb00a703bdb8f87ed420626d44ab37403a 100644 (file)
@@ -577,7 +577,7 @@ int tls_handshake_recv(REQUEST *request, tls_session_t *ssn)
        /*
         *      Cache the SSL_SESSION pointer.
         */
-       if (SSL_is_init_finished(ssn->ssl)) {
+       if (!ssn->ssl_session && SL_is_init_finished(ssn->ssl)) {
                ssn->ssl_session = SSL_get_session(ssn->ssl);
                if (!ssn->ssl_session) {
                        RDEBUG("Failed getting SSL session");