Router: removed two unused assignments.

This should resolve some static analyzers warnings.
This commit is contained in:
Valentin Bartenev
2020-05-15 17:08:37 +03:00
parent 82471c1dd3
commit 79f5e531fe
2 changed files with 2 additions and 5 deletions

View File

@@ -1050,9 +1050,6 @@ nxt_http_route_pattern_create(nxt_task_t *task, nxt_mp_t *mp,
nxt_uint_t n, length; nxt_uint_t n, length;
nxt_http_route_pattern_type_t type; nxt_http_route_pattern_type_t type;
/* Suppress warning about uninitialized variable. */
length = 0;
type = NXT_HTTP_ROUTE_PATTERN_EXACT; type = NXT_HTTP_ROUTE_PATTERN_EXACT;
nxt_conf_get_string(cv, &test); nxt_conf_get_string(cv, &test);

View File

@@ -1614,7 +1614,7 @@ nxt_router_conf_create(nxt_task_t *task, nxt_router_temp_conf_t *tmcf,
next_target = 0; next_target = 0;
for (i = 0; i < n; i++) { for (i = 0; i < n; i++) {
value = nxt_conf_next_object_member(apcf.targets_value, (void) nxt_conf_next_object_member(apcf.targets_value,
&target, &next_target); &target, &next_target);
s = nxt_str_dup(app_mp, &targets[i], &target); s = nxt_str_dup(app_mp, &targets[i], &target);