apps: use else if when checking for headers in the http server code

Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Shane Lontis <shane.lontis@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/15300)
This commit is contained in:
Pauli 2021-05-17 18:16:28 +10:00
parent 4547a71930
commit a94d62ab23

View File

@ -457,7 +457,7 @@ int http_server_get_asn1_req(const ASN1_ITEM *it, ASN1_VALUE **preq,
if (found_keep_alive != NULL && strcasecmp(key, "Connection") == 0) {
if (strcasecmp(value, "keep-alive") == 0)
*found_keep_alive = 1;
if (strcasecmp(value, "close") == 0)
else if (strcasecmp(value, "close") == 0)
*found_keep_alive = 0;
}
}