use SSL3_VERSION_MAJOR instead of SSL3_VERSION etc.
authorNils Larsch <nils@openssl.org>
Fri, 1 Apr 2005 17:33:39 +0000 (17:33 +0000)
committerNils Larsch <nils@openssl.org>
Fri, 1 Apr 2005 17:33:39 +0000 (17:33 +0000)
PR: 658

ssl/ssl_asn1.c

index 27c4b86ed4c12a5e56a80cecba3bb7d754fd073d..4d5900ad2f250e12f15a9c35b453306e68d6c5a0 100644 (file)
@@ -266,7 +266,7 @@ SSL_SESSION *d2i_SSL_SESSION(SSL_SESSION **a, const unsigned char * const *pp,
                        ((unsigned long)os.data[1]<< 8L)|
                         (unsigned long)os.data[2];
                }
-       else if ((ssl_version>>8) == 3)
+       else if ((ssl_version>>8) == SSL3_VERSION_MAJOR)
                {
                if (os.length != 2)
                        {
@@ -287,9 +287,9 @@ SSL_SESSION *d2i_SSL_SESSION(SSL_SESSION **a, const unsigned char * const *pp,
        ret->cipher_id=id;
 
        M_ASN1_D2I_get(osp,d2i_ASN1_OCTET_STRING);
-       if ((ssl_version>>8) == SSL3_VERSION)
+       if ((ssl_version>>8) == SSL3_VERSION_MAJOR)
                i=SSL3_MAX_SSL_SESSION_ID_LENGTH;
-       else /* if (ssl_version == SSL2_VERSION) */
+       else /* if (ssl_version == SSL2_VERSION_MAJOR) */
                i=SSL2_MAX_SSL_SESSION_ID_LENGTH;
 
        if (os.length > i)