mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2025-03-11 05:48:41 +00:00
CLEANUP: ssl: rename new_ckch_store_load_files_path() to ckch_store_new_load_files_path()
Rename the new_ckch_store_load_files_path() function to ckch_store_new_load_files_path(), in order to be more consistent.
This commit is contained in:
parent
10ab56831e
commit
964f093504
@ -37,7 +37,7 @@ int ssl_sock_load_sctl_from_file(const char *sctl_path, char *buf, struct ckch_d
|
||||
int ssl_sock_load_issuer_file_into_ckch(const char *path, char *buf, struct ckch_data *data, char **err);
|
||||
|
||||
/* ckch_store functions */
|
||||
struct ckch_store *new_ckch_store_load_files_path(char *path, char **err);
|
||||
struct ckch_store *ckch_store_new_load_files_path(char *path, char **err);
|
||||
struct ckch_store *ckchs_lookup(char *path);
|
||||
struct ckch_store *ckchs_dup(const struct ckch_store *src);
|
||||
struct ckch_store *ckch_store_new(const char *filename);
|
||||
|
@ -995,7 +995,7 @@ struct ckch_store *ckchs_lookup(char *path)
|
||||
/*
|
||||
* This function allocate a ckch_store and populate it with certificates from files.
|
||||
*/
|
||||
struct ckch_store *new_ckch_store_load_files_path(char *path, char **err)
|
||||
struct ckch_store *ckch_store_new_load_files_path(char *path, char **err)
|
||||
{
|
||||
struct ckch_store *ckchs;
|
||||
|
||||
|
@ -592,7 +592,7 @@ int crtlist_parse_file(char *file, struct bind_conf *bind_conf, struct proxy *cu
|
||||
if (stat(crt_path, &buf) == 0) {
|
||||
found++;
|
||||
|
||||
ckchs = new_ckch_store_load_files_path(crt_path, err);
|
||||
ckchs = ckch_store_new_load_files_path(crt_path, err);
|
||||
if (ckchs == NULL) {
|
||||
cfgerr |= ERR_ALERT | ERR_FATAL;
|
||||
goto error;
|
||||
@ -629,7 +629,7 @@ int crtlist_parse_file(char *file, struct bind_conf *bind_conf, struct proxy *cu
|
||||
ckchs = ckchs_lookup(fp);
|
||||
if (!ckchs) {
|
||||
if (stat(fp, &buf) == 0) {
|
||||
ckchs = new_ckch_store_load_files_path(fp, err);
|
||||
ckchs = ckch_store_new_load_files_path(fp, err);
|
||||
if (!ckchs) {
|
||||
cfgerr |= ERR_ALERT | ERR_FATAL;
|
||||
goto error;
|
||||
@ -782,7 +782,7 @@ int crtlist_load_cert_dir(char *path, struct bind_conf *bind_conf, struct crtlis
|
||||
|
||||
ckchs = ckchs_lookup(fp);
|
||||
if (ckchs == NULL)
|
||||
ckchs = new_ckch_store_load_files_path(fp, err);
|
||||
ckchs = ckch_store_new_load_files_path(fp, err);
|
||||
if (ckchs == NULL) {
|
||||
free(de);
|
||||
free(entry);
|
||||
|
@ -3858,7 +3858,7 @@ int ssl_sock_load_cert(char *path, struct bind_conf *bind_conf, int is_default,
|
||||
} else if (stat(path, &buf) == 0) {
|
||||
found++;
|
||||
if (S_ISDIR(buf.st_mode) == 0) {
|
||||
ckchs = new_ckch_store_load_files_path(path, err);
|
||||
ckchs = ckch_store_new_load_files_path(path, err);
|
||||
if (!ckchs)
|
||||
cfgerr |= ERR_ALERT | ERR_FATAL;
|
||||
cfgerr |= ssl_sock_load_ckchs(path, ckchs, bind_conf, NULL, NULL, 0, is_default, &ckch_inst, err);
|
||||
@ -3886,7 +3886,7 @@ int ssl_sock_load_cert(char *path, struct bind_conf *bind_conf, int is_default,
|
||||
} else {
|
||||
if (stat(fp, &buf) == 0) {
|
||||
found++;
|
||||
ckchs = new_ckch_store_load_files_path(fp, err);
|
||||
ckchs = ckch_store_new_load_files_path(fp, err);
|
||||
if (!ckchs)
|
||||
cfgerr |= ERR_ALERT | ERR_FATAL;
|
||||
cfgerr |= ssl_sock_load_ckchs(fp, ckchs, bind_conf, NULL, NULL, 0, is_default, &ckch_inst, err);
|
||||
@ -3939,7 +3939,7 @@ int ssl_sock_load_srv_cert(char *path, struct server *server, int create_if_none
|
||||
/* We do not manage directories on backend side. */
|
||||
if (S_ISDIR(buf.st_mode) == 0) {
|
||||
++found;
|
||||
ckchs = new_ckch_store_load_files_path(path, err);
|
||||
ckchs = ckch_store_new_load_files_path(path, err);
|
||||
if (!ckchs)
|
||||
cfgerr |= ERR_ALERT | ERR_FATAL;
|
||||
cfgerr |= ssl_sock_load_srv_ckchs(path, ckchs, server, &server->ssl_ctx.inst, err);
|
||||
|
Loading…
Reference in New Issue
Block a user