nxt_router.c (2050:d1298cc3f385) nxt_router.c (2077:624e51cfe97a)
1
2/*
3 * Copyright (C) Igor Sysoev
4 * Copyright (C) Valentin V. Bartenev
5 * Copyright (C) NGINX, Inc.
6 */
7
8#include <nxt_router.h>

--- 1910 unchanged lines hidden (view full) ---

1919 }
1920
1921 tls_init->conf_cmds = nxt_conf_get_path(listener,
1922 &conf_commands_path);
1923
1924 tls_init->tickets_conf = nxt_conf_get_path(listener,
1925 &conf_tickets);
1926
1
2/*
3 * Copyright (C) Igor Sysoev
4 * Copyright (C) Valentin V. Bartenev
5 * Copyright (C) NGINX, Inc.
6 */
7
8#include <nxt_router.h>

--- 1910 unchanged lines hidden (view full) ---

1919 }
1920
1921 tls_init->conf_cmds = nxt_conf_get_path(listener,
1922 &conf_commands_path);
1923
1924 tls_init->tickets_conf = nxt_conf_get_path(listener,
1925 &conf_tickets);
1926
1927 if (nxt_conf_type(certificate) == NXT_CONF_ARRAY) {
1928 n = nxt_conf_array_elements_count(certificate);
1927 n = nxt_conf_array_elements_count_or_1(certificate);
1929
1928
1930 for (i = 0; i < n; i++) {
1931 value = nxt_conf_get_array_element(certificate, i);
1929 for (i = 0; i < n; i++) {
1930 value = nxt_conf_get_array_element_or_itself(certificate,
1931 i);
1932 nxt_assert(value != NULL);
1932
1933
1933 nxt_assert(value != NULL);
1934
1935 ret = nxt_router_conf_tls_insert(tmcf, value, skcf,
1936 tls_init, i == 0);
1937 if (nxt_slow_path(ret != NXT_OK)) {
1938 goto fail;
1939 }
1940 }
1941
1942 } else {
1943 /* NXT_CONF_STRING */
1944 ret = nxt_router_conf_tls_insert(tmcf, certificate, skcf,
1945 tls_init, 1);
1934 ret = nxt_router_conf_tls_insert(tmcf, value, skcf,
1935 tls_init, i == 0);
1946 if (nxt_slow_path(ret != NXT_OK)) {
1947 goto fail;
1948 }
1949 }
1950 }
1951#endif
1952
1953 skcf->listen->handler = nxt_http_conn_init;

--- 4024 unchanged lines hidden ---
1936 if (nxt_slow_path(ret != NXT_OK)) {
1937 goto fail;
1938 }
1939 }
1940 }
1941#endif
1942
1943 skcf->listen->handler = nxt_http_conn_init;

--- 4024 unchanged lines hidden ---