mirror of
https://github.com/cesanta/mongoose.git
synced 2026-10-17 10:49:47 +00:00
Squash warning
This commit is contained in:
1 parent
0f83c2a6e5
commit
af7602497d
2 files changed
+2
-2
No files matched your search
+1
-1
@@ -12415,7 +12415,7 @@ static int mg_tls_recv_cert(struct mg_connection *c, bool is_client) {
|
||||
if (ci == certs) {
|
||||
// First certificate in the chain is peer cert, check SAN if requested,
|
||||
// and store public key for further CertVerify step
|
||||
if (tls->hostname != NULL && *tls->hostname != '\0' &&
|
||||
if (tls->hostname[0] != '\0' &&
|
||||
mg_tls_verify_cert_san(cert, certsz, tls->hostname) <= 0 &&
|
||||
mg_tls_verify_cert_cn(&ci->subj, tls->hostname) <= 0) {
|
||||
mg_error(c, "failed to verify hostname");
|
||||
|
||||
+1
-1
@@ -1343,7 +1343,7 @@ static int mg_tls_recv_cert(struct mg_connection *c, bool is_client) {
|
||||
if (ci == certs) {
|
||||
// First certificate in the chain is peer cert, check SAN if requested,
|
||||
// and store public key for further CertVerify step
|
||||
if (tls->hostname != NULL && *tls->hostname != '\0' &&
|
||||
if (tls->hostname[0] != '\0' &&
|
||||
mg_tls_verify_cert_san(cert, certsz, tls->hostname) <= 0 &&
|
||||
mg_tls_verify_cert_cn(&ci->subj, tls->hostname) <= 0) {
|
||||
mg_error(c, "failed to verify hostname");
|
||||
|
||||
Reference in new issue
Block a user