mirror of
https://github.com/apache/httpd.git
synced 2025-08-05 16:55:50 +03:00
Layout and compiler warning.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@424735 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
@@ -668,7 +668,7 @@ static void ssl_init_ctx_cert_chain(server_rec *s,
|
||||
const char *chain = mctx->cert_chain;
|
||||
|
||||
if (mctx->pkcs7) {
|
||||
ssl_init_ctx_pkcs7_cert_chain(s,mctx);
|
||||
ssl_init_ctx_pkcs7_cert_chain(s, mctx);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@@ -199,13 +199,15 @@ void ssl_pphrase_Handle(server_rec *s, apr_pool_t *p)
|
||||
&& (sc->server->pks->cert_files[i] != NULL
|
||||
|| sc->server->pkcs7); i++) {
|
||||
if (sc->server->pkcs7) {
|
||||
STACK_OF(X509) *certs = ssl_read_pkcs7(pServ, sc->server->pkcs7);
|
||||
|
||||
STACK_OF(X509) *certs = ssl_read_pkcs7(pServ,
|
||||
sc->server->pkcs7);
|
||||
pX509Cert = sk_X509_value(certs, 0);
|
||||
i = SSL_AIDX_MAX;
|
||||
} else {
|
||||
apr_cpystrn(szPath, sc->server->pks->cert_files[i], sizeof(szPath));
|
||||
if ((rv = exists_and_readable(szPath, p, NULL)) != APR_SUCCESS) {
|
||||
apr_cpystrn(szPath, sc->server->pks->cert_files[i],
|
||||
sizeof(szPath));
|
||||
if ((rv = exists_and_readable(szPath, p, NULL))
|
||||
!= APR_SUCCESS) {
|
||||
ap_log_error(APLOG_MARK, APLOG_ERR, rv, s,
|
||||
"Init: Can't open server certificate file %s",
|
||||
szPath);
|
||||
@@ -213,7 +215,8 @@ void ssl_pphrase_Handle(server_rec *s, apr_pool_t *p)
|
||||
}
|
||||
if ((pX509Cert = SSL_read_X509(szPath, NULL, NULL)) == NULL) {
|
||||
ap_log_error(APLOG_MARK, APLOG_ERR, 0, s,
|
||||
"Init: Unable to read server certificate from file %s", szPath);
|
||||
"Init: Unable to read server certificate from"
|
||||
" file %s", szPath);
|
||||
ssl_log_ssl_error(APLOG_MARK, APLOG_ERR, s);
|
||||
ssl_die();
|
||||
}
|
||||
|
@@ -268,7 +268,7 @@ const char *ssl_asn1_table_keyfmt(apr_pool_t *p,
|
||||
STACK_OF(X509) *ssl_read_pkcs7(server_rec *s,const char *pkcs7)
|
||||
{
|
||||
PKCS7 *p7;
|
||||
STACK_OF(X509) *certs;
|
||||
STACK_OF(X509) *certs = NULL;
|
||||
FILE *f;
|
||||
|
||||
f = fopen(pkcs7, "r");
|
||||
@@ -306,6 +306,8 @@ STACK_OF(X509) *ssl_read_pkcs7(server_rec *s,const char *pkcs7)
|
||||
ssl_die();
|
||||
}
|
||||
|
||||
fclose(f);
|
||||
|
||||
return certs;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user