diff options
author | Konstantin Pavlov <thresh@nginx.com> | 2022-06-02 16:51:49 +0400 |
---|---|---|
committer | Konstantin Pavlov <thresh@nginx.com> | 2022-06-02 16:51:49 +0400 |
commit | d9fddee1dbfc1f5d49c8f40386289d7188030952 (patch) | |
tree | 842a62b343ac33eba10e7a426a10b55bb1c46aed /src/nxt_conf_validation.c | |
parent | 420395ee2e7cd464e157c49bea3d74f15bf25f30 (diff) | |
parent | 0d48fe73c4450901622373e35f6ff3a944ec13d6 (diff) | |
download | unit-d9fddee1dbfc1f5d49c8f40386289d7188030952.tar.gz unit-d9fddee1dbfc1f5d49c8f40386289d7188030952.tar.bz2 |
Merged with the default branch.1.27.0-1
Diffstat (limited to 'src/nxt_conf_validation.c')
-rw-r--r-- | src/nxt_conf_validation.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/src/nxt_conf_validation.c b/src/nxt_conf_validation.c index 3f068bbb..ee7ebe44 100644 --- a/src/nxt_conf_validation.c +++ b/src/nxt_conf_validation.c @@ -77,7 +77,8 @@ static nxt_int_t nxt_conf_vldt_error(nxt_conf_validation_t *vldt, static nxt_int_t nxt_conf_vldt_var(nxt_conf_validation_t *vldt, nxt_str_t *name, nxt_str_t *value); nxt_inline nxt_int_t nxt_conf_vldt_unsupported(nxt_conf_validation_t *vldt, - nxt_conf_value_t *value, void *data); + nxt_conf_value_t *value, void *data) + NXT_MAYBE_UNUSED; static nxt_int_t nxt_conf_vldt_mtypes(nxt_conf_validation_t *vldt, nxt_conf_value_t *value, void *data); @@ -114,7 +115,7 @@ static nxt_int_t nxt_conf_vldt_pass(nxt_conf_validation_t *vldt, static nxt_int_t nxt_conf_vldt_return(nxt_conf_validation_t *vldt, nxt_conf_value_t *value, void *data); static nxt_int_t nxt_conf_vldt_share(nxt_conf_validation_t *vldt, - nxt_conf_value_t *value, void *data); + nxt_conf_value_t *value, void *data); static nxt_int_t nxt_conf_vldt_share_element(nxt_conf_validation_t *vldt, nxt_conf_value_t *value); static nxt_int_t nxt_conf_vldt_proxy(nxt_conf_validation_t *vldt, @@ -194,7 +195,7 @@ static nxt_int_t nxt_conf_vldt_java_classpath(nxt_conf_validation_t *vldt, static nxt_int_t nxt_conf_vldt_java_option(nxt_conf_validation_t *vldt, nxt_conf_value_t *value); static nxt_int_t nxt_conf_vldt_upstream(nxt_conf_validation_t *vldt, - nxt_str_t *name, nxt_conf_value_t *value); + nxt_str_t *name, nxt_conf_value_t *value); static nxt_int_t nxt_conf_vldt_server(nxt_conf_validation_t *vldt, nxt_str_t *name, nxt_conf_value_t *value); static nxt_int_t nxt_conf_vldt_server_weight(nxt_conf_validation_t *vldt, @@ -634,6 +635,7 @@ static nxt_conf_vldt_object_t nxt_conf_vldt_return_action_members[] = { }, { .name = nxt_string("location"), .type = NXT_CONF_VLDT_STRING, + .flags = NXT_CONF_VLDT_VAR, }, NXT_CONF_VLDT_END @@ -646,6 +648,9 @@ static nxt_conf_vldt_object_t nxt_conf_vldt_share_action_members[] = { .type = NXT_CONF_VLDT_STRING | NXT_CONF_VLDT_ARRAY, .validator = nxt_conf_vldt_share, }, { + .name = nxt_string("index"), + .type = NXT_CONF_VLDT_STRING, + }, { .name = nxt_string("types"), .type = NXT_CONF_VLDT_STRING | NXT_CONF_VLDT_ARRAY, .validator = nxt_conf_vldt_match_patterns, @@ -2448,7 +2453,7 @@ nxt_conf_vldt_object(nxt_conf_validation_t *vldt, nxt_conf_value_t *value, break; } - } + } ret = nxt_conf_vldt_type(vldt, &name, member, vals->type); if (ret != NXT_OK) { |