Welcome! Log In Create A New Profile

Advanced

[nginx] svn commit: r4563 - trunk/src/http/modules

Anonymous User
March 28, 2012 05:30AM
Author: ru
Date: 2012-03-28 09:29:09 +0000 (Wed, 28 Mar 2012)
New Revision: 4563
URL: http://trac.nginx.org/nginx/changeset/4563/nginx

Log:
Replaced ngx_http_realip_from_t with ngx_in_cidr_t.


Modified:
trunk/src/http/modules/ngx_http_realip_module.c

Modified: trunk/src/http/modules/ngx_http_realip_module.c
===================================================================
--- trunk/src/http/modules/ngx_http_realip_module.c 2012-03-28 06:50:23 UTC (rev 4562)
+++ trunk/src/http/modules/ngx_http_realip_module.c 2012-03-28 09:29:09 UTC (rev 4563)
@@ -16,13 +16,7 @@


typedef struct {
- in_addr_t mask;
- in_addr_t addr;
-} ngx_http_realip_from_t;
-
-
-typedef struct {
- ngx_array_t *from; /* array of ngx_http_realip_from_t */
+ ngx_array_t *from; /* array of ngx_in_cidr_t */
ngx_uint_t type;
ngx_uint_t hash;
ngx_str_t header;
@@ -114,9 +108,9 @@
ngx_list_part_t *part;
ngx_table_elt_t *header;
struct sockaddr_in *sin;
+ ngx_in_cidr_t *from;
ngx_connection_t *c;
ngx_http_realip_ctx_t *ctx;
- ngx_http_realip_from_t *from;
ngx_http_realip_loc_conf_t *rlcf;

ctx = ngx_http_get_module_ctx(r, ngx_http_realip_module);
@@ -317,7 +311,7 @@
ngx_int_t rc;
ngx_str_t *value;
ngx_cidr_t cidr;
- ngx_http_realip_from_t *from;
+ ngx_in_cidr_t *from;

value = cf->args->elts;

@@ -332,7 +326,7 @@

if (rlcf->from == NULL) {
rlcf->from = ngx_array_create(cf->pool, 2,
- sizeof(ngx_http_realip_from_t));
+ sizeof(ngx_in_cidr_t));
if (rlcf->from == NULL) {
return NGX_CONF_ERROR;
}

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

[nginx] svn commit: r4563 - trunk/src/http/modules

Anonymous User 1038 March 28, 2012 05:30AM



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

Online Users

Guests: 306
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready