Merge pull request #851 from J-Feng/master

Uninitialized variable `l` results in cert length mismatch error
This commit is contained in:
Zhi Guan
2020-07-06 12:26:34 +08:00
committed by GitHub

View File

@@ -1339,7 +1339,7 @@ int gmtls_construct_client_certificate(SSL *s)
int al = -1;
unsigned long alg_a = s->s3->tmp.new_cipher->algorithm_auth;
unsigned char *p;
int l;
int l = 3 + SSL_HM_HEADER_LENGTH(s);
if (alg_a & SSL_aSM2) {
if (!gmtls_construct_sm2_certs(s, &l)) {