From: Matthieu Crapet Date: Fri, 8 Aug 2014 22:03:58 +0000 (-0400) Subject: RT 1505: Use SSL3_AL_FATAL not "2" X-Git-Tag: master-post-reformat~537 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=6d03125ccf0fd870792a4fa9f6140f9983f241a6;p=oweals%2Fopenssl.git RT 1505: Use SSL3_AL_FATAL not "2" Use SSL3_AL_FATAL instead of the literal constant "2" Every bit of cleanup helps. Reviewed-by: Matt Caswell --- diff --git a/ssl/s3_pkt.c b/ssl/s3_pkt.c index 8fc3bb4e0b..9a1d65d8cb 100644 --- a/ssl/s3_pkt.c +++ b/ssl/s3_pkt.c @@ -1793,7 +1793,7 @@ int ssl3_send_alert(SSL *s, int level, int desc) desc = SSL_AD_HANDSHAKE_FAILURE; /* SSL 3.0 does not have protocol_version alerts */ if (desc < 0) return -1; /* If a fatal one, remove from cache */ - if ((level == 2) && (s->session != NULL)) + if ((level == SSL3_AL_FATAL) && (s->session != NULL)) SSL_CTX_remove_session(s->ctx,s->session); s->s3->alert_dispatch=1;