Welcome! Log In Create A New Profile

Advanced

[nginx] Upstream keepalive: slightly simplified code.

Ruslan Ermilov
May 15, 2013 07:06AM
details: http://hg.nginx.org/nginx/rev/822b82191940
branches:
changeset: 5213:822b82191940
user: Ruslan Ermilov <ru@nginx.com>
date: Wed May 15 15:04:49 2013 +0400
description:
Upstream keepalive: slightly simplified code.

diffstat:

src/http/modules/ngx_http_upstream_keepalive_module.c | 7 ++-----
1 files changed, 2 insertions(+), 5 deletions(-)

diffs (31 lines):

diff -r 09dbd363050a -r 822b82191940 src/http/modules/ngx_http_upstream_keepalive_module.c
--- a/src/http/modules/ngx_http_upstream_keepalive_module.c Thu Apr 25 17:41:45 2013 +0400
+++ b/src/http/modules/ngx_http_upstream_keepalive_module.c Wed May 15 15:04:49 2013 +0400
@@ -81,7 +81,7 @@ static ngx_command_t ngx_http_upstream_
{ ngx_string("keepalive"),
NGX_HTTP_UPS_CONF|NGX_CONF_TAKE12,
ngx_http_upstream_keepalive,
- 0,
+ NGX_HTTP_SRV_CONF_OFFSET,
0,
NULL },

@@ -481,7 +481,7 @@ static char *
ngx_http_upstream_keepalive(ngx_conf_t *cf, ngx_command_t *cmd, void *conf)
{
ngx_http_upstream_srv_conf_t *uscf;
- ngx_http_upstream_keepalive_srv_conf_t *kcf;
+ ngx_http_upstream_keepalive_srv_conf_t *kcf = conf;

ngx_int_t n;
ngx_str_t *value;
@@ -489,9 +489,6 @@ ngx_http_upstream_keepalive(ngx_conf_t *

uscf = ngx_http_conf_get_module_srv_conf(cf, ngx_http_upstream_module);

- kcf = ngx_http_conf_upstream_srv_conf(uscf,
- ngx_http_upstream_keepalive_module);
-
if (kcf->original_init_upstream) {
return "is duplicate";
}

_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

[nginx] Upstream keepalive: slightly simplified code.

Ruslan Ermilov 772 May 15, 2013 07:06AM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 158
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 500 on July 15, 2024
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready