Deleted
Added
nxt_router.c (1392:eef15777af49) | nxt_router.c (1394:20b41ebfff79) |
---|---|
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> --- 1620 unchanged lines hidden (view full) --- 1629 if (nxt_fast_path(routes_conf != NULL)) { 1630 routes = nxt_http_routes_create(task, tmcf, routes_conf); 1631 if (nxt_slow_path(routes == NULL)) { 1632 return NXT_ERROR; 1633 } 1634 tmcf->router_conf->routes = routes; 1635 } 1636 | 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> --- 1620 unchanged lines hidden (view full) --- 1629 if (nxt_fast_path(routes_conf != NULL)) { 1630 routes = nxt_http_routes_create(task, tmcf, routes_conf); 1631 if (nxt_slow_path(routes == NULL)) { 1632 return NXT_ERROR; 1633 } 1634 tmcf->router_conf->routes = routes; 1635 } 1636 |
1637 ret = nxt_upstreams_create(task, tmcf, conf); 1638 if (nxt_slow_path(ret != NXT_OK)) { 1639 return ret; 1640 } 1641 |
|
1637 http = nxt_conf_get_path(conf, &http_path); 1638#if 0 1639 if (http == NULL) { 1640 nxt_alert(task, "no \"http\" block"); 1641 return NXT_ERROR; 1642 } 1643#endif 1644 --- 876 unchanged lines hidden (view full) --- 2521} 2522 2523 2524static nxt_int_t 2525nxt_router_engine_joints_create(nxt_router_temp_conf_t *tmcf, 2526 nxt_router_engine_conf_t *recf, nxt_queue_t *sockets, 2527 nxt_work_handler_t handler) 2528{ | 1642 http = nxt_conf_get_path(conf, &http_path); 1643#if 0 1644 if (http == NULL) { 1645 nxt_alert(task, "no \"http\" block"); 1646 return NXT_ERROR; 1647 } 1648#endif 1649 --- 876 unchanged lines hidden (view full) --- 2526} 2527 2528 2529static nxt_int_t 2530nxt_router_engine_joints_create(nxt_router_temp_conf_t *tmcf, 2531 nxt_router_engine_conf_t *recf, nxt_queue_t *sockets, 2532 nxt_work_handler_t handler) 2533{ |
2534 nxt_int_t ret; |
|
2529 nxt_joint_job_t *job; 2530 nxt_queue_link_t *qlk; 2531 nxt_socket_conf_t *skcf; 2532 nxt_socket_conf_joint_t *joint; 2533 2534 for (qlk = nxt_queue_first(sockets); 2535 qlk != nxt_queue_tail(sockets); 2536 qlk = nxt_queue_next(qlk)) --- 17 unchanged lines hidden (view full) --- 2554 joint = nxt_mp_alloc(tmcf->router_conf->mem_pool, 2555 sizeof(nxt_socket_conf_joint_t)); 2556 if (nxt_slow_path(joint == NULL)) { 2557 return NXT_ERROR; 2558 } 2559 2560 job->work.data = joint; 2561 | 2535 nxt_joint_job_t *job; 2536 nxt_queue_link_t *qlk; 2537 nxt_socket_conf_t *skcf; 2538 nxt_socket_conf_joint_t *joint; 2539 2540 for (qlk = nxt_queue_first(sockets); 2541 qlk != nxt_queue_tail(sockets); 2542 qlk = nxt_queue_next(qlk)) --- 17 unchanged lines hidden (view full) --- 2560 joint = nxt_mp_alloc(tmcf->router_conf->mem_pool, 2561 sizeof(nxt_socket_conf_joint_t)); 2562 if (nxt_slow_path(joint == NULL)) { 2563 return NXT_ERROR; 2564 } 2565 2566 job->work.data = joint; 2567 |
2568 ret = nxt_upstreams_joint_create(tmcf, &joint->upstreams); 2569 if (nxt_slow_path(ret != NXT_OK)) { 2570 return ret; 2571 } 2572 |
|
2562 joint->count = 1; 2563 2564 skcf = nxt_queue_link_data(qlk, nxt_socket_conf_t, link); 2565 skcf->count++; 2566 joint->socket_conf = skcf; 2567 2568 joint->engine = recf->engine; 2569 } --- 2750 unchanged lines hidden --- | 2573 joint->count = 1; 2574 2575 skcf = nxt_queue_link_data(qlk, nxt_socket_conf_t, link); 2576 skcf->count++; 2577 joint->socket_conf = skcf; 2578 2579 joint->engine = recf->engine; 2580 } --- 2750 unchanged lines hidden --- |