comparison src/http/ngx_http_request.c @ 2980:c96960a4b42c

skip URI trailing dots under Win32
author Igor Sysoev <igor@sysoev.ru>
date Tue, 14 Jul 2009 08:51:20 +0000
parents 87ddbe960172
children 2465ff3da161
comparison
equal deleted inserted replaced
2979:b941147f2b2e 2980:c96960a4b42c
764 if (r->args_start && r->uri_end > r->args_start) { 764 if (r->args_start && r->uri_end > r->args_start) {
765 r->args.len = r->uri_end - r->args_start; 765 r->args.len = r->uri_end - r->args_start;
766 r->args.data = r->args_start; 766 r->args.data = r->args_start;
767 } 767 }
768 768
769 #if (NGX_WIN32)
770 {
771 u_char *p;
772
773 p = r->uri.data + r->uri.len - 1;
774
775 if (*p == '.') {
776
777 while (--p > r->uri.data && *p == '.') { /* void */ }
778
779 r->uri.len = p + 1 - r->uri.data;
780
781 ngx_http_set_exten(r);
782 }
783 }
784 #endif
769 785
770 ngx_log_debug1(NGX_LOG_DEBUG_HTTP, c->log, 0, 786 ngx_log_debug1(NGX_LOG_DEBUG_HTTP, c->log, 0,
771 "http request line: \"%V\"", &r->request_line); 787 "http request line: \"%V\"", &r->request_line);
772 788
773 ngx_log_debug1(NGX_LOG_DEBUG_HTTP, c->log, 0, 789 ngx_log_debug1(NGX_LOG_DEBUG_HTTP, c->log, 0,