]> git.kaiwu.me - nginx.git/log
nginx.git
12 years agoFixed ngx_http_parse_chunked() minimal length calculation.
Maxim Dounin [Fri, 28 Jun 2013 09:55:05 +0000 (13:55 +0400)]
Fixed ngx_http_parse_chunked() minimal length calculation.

Minimal data length we expect for further calls was calculated incorrectly
if parsing stopped right after parsing chunk size.  This might in theory
affect clients and/or backends using LF instead of CRLF.

Patch by Dmitry Popov.

12 years agoFixed build on Linux with x32 ABI.
Maxim Dounin [Wed, 26 Jun 2013 11:47:27 +0000 (15:47 +0400)]
Fixed build on Linux with x32 ABI.

On Linux x32 inclusion of sys/sysctl.h produces an error.  As sysctl() is
only used by rtsig event method code, which is legacy and not compiled
in by default on modern linuxes, the sys/sysctl.h file now only included
if rtsig support is enabled.

Based on patch by Serguei I. Ivantsov.

12 years agoCore: support several "error_log" directives.
Vladimir Homutov [Thu, 20 Jun 2013 16:47:39 +0000 (20:47 +0400)]
Core: support several "error_log" directives.

When several "error_log" directives are specified in the same configuration
block, logs are written to all files with a matching log level.

All logs are stored in the singly-linked list that is sorted by log level in
the descending order.

Specific debug levels (NGX_LOG_DEBUG_HTTP,EVENT, etc.) are not supported
if several "error_log" directives are specified.  In this case all logs
will use debug level that has largest absolute value.

12 years agoSimplified ngx_list_create().
Ruslan Ermilov [Wed, 19 Jun 2013 04:55:08 +0000 (08:55 +0400)]
Simplified ngx_list_create().

12 years agoValgrind: another complaint about uninitialized bytes.
Tatsuhiko Kubo [Tue, 11 Jun 2013 15:41:24 +0000 (00:41 +0900)]
Valgrind: another complaint about uninitialized bytes.

12 years agoSPDY: fixed code style, no functional changes.
Valentin Bartenev [Thu, 13 Jun 2013 12:28:42 +0000 (16:28 +0400)]
SPDY: fixed code style, no functional changes.

12 years agoCore: moved initialization of log level.
Vladimir Homutov [Thu, 13 Jun 2013 10:50:10 +0000 (14:50 +0400)]
Core: moved initialization of log level.

The cycle->new_log->log_level should only be initialized by ngx_init_cycle()
if no error logs were found in the configuration.  This move allows to get rid
of extra initialization in ngx_error_log().

12 years agoSPDY: pass through the full status when available.
Jim Radford [Fri, 7 Jun 2013 20:16:00 +0000 (13:16 -0700)]
SPDY: pass through the full status when available.

Avoid stripping the status text when proxying for compatibility with http.

12 years agoPerl: fixed r->header_in("Cookie") (ticket #351).
Maxim Dounin [Mon, 10 Jun 2013 10:35:00 +0000 (14:35 +0400)]
Perl: fixed r->header_in("Cookie") (ticket #351).

It was broken by X-Forwarded-For related changes in f7fe817c92a2 (1.3.14)
as hh->offset is no longer 0 for Cookie.

12 years agoFixed debug logging in ngx_http_parse_complex_uri().
Maxim Dounin [Wed, 5 Jun 2013 15:45:08 +0000 (19:45 +0400)]
Fixed debug logging in ngx_http_parse_complex_uri().

The *u previously logged isn't yet initialized at this point, and
Valgrind complains.

12 years agoMail: fixed possible uninitialized memory access.
Maxim Dounin [Wed, 5 Jun 2013 15:44:23 +0000 (19:44 +0400)]
Mail: fixed possible uninitialized memory access.

Found by Valgrind.

12 years agoValgrind: supressed complaints about uninitialized bytes.
Maxim Dounin [Wed, 5 Jun 2013 15:44:22 +0000 (19:44 +0400)]
Valgrind: supressed complaints about uninitialized bytes.

Valgrind complains if we pass uninitialized memory to a syscall:

==36492== Syscall param sendmsg(msg.msg_iov[0]) points to uninitialised byte(s)
==36492==    at 0x6B5E6A: sendmsg (in /usr/lib/system/libsystem_kernel.dylib)
==36492==    by 0x10004288E: ngx_signal_worker_processes (ngx_process_cycle.c:527)
==36492==    by 0x1000417A7: ngx_master_process_cycle (ngx_process_cycle.c:203)
==36492==    by 0x100001F10: main (nginx.c:410)
==36492==  Address 0x7fff5fbff71c is on thread 1's stack

Even initialization of all members of the structure passed isn't enough, as
there is padding which still remains uninitialized and results in Valgrind
complaint.  Note there is no real problem here as data from uninitialized
memory isn't used.

12 years agoValgrind: sigaction() failure now ignored.
Maxim Dounin [Wed, 5 Jun 2013 15:44:20 +0000 (19:44 +0400)]
Valgrind: sigaction() failure now ignored.

Valgrind intercepts SIGUSR2 in some cases, and nginx might not be able to
start due to sigaction() failure.  If compiled with NGX_VALGRIND defined,
we now ignore the failure of sigaction().

12 years agoStatus: the "last_in_chain" flag must be set.
Valentin Bartenev [Wed, 5 Jun 2013 12:22:40 +0000 (16:22 +0400)]
Status: the "last_in_chain" flag must be set.

The module always produces only one and obviously the last buffer in chain.

12 years agoSPDY: use proper macros for value length and headers counter.
Valentin Bartenev [Tue, 4 Jun 2013 22:13:52 +0000 (02:13 +0400)]
SPDY: use proper macros for value length and headers counter.

Currently these macros are synonyms, but this may change in the future
(in particular, spdy/3 uses 4 bytes for lengths).

12 years agoVersion bump.
Maxim Dounin [Tue, 4 Jun 2013 15:38:20 +0000 (19:38 +0400)]
Version bump.

12 years agoCore: fixed handling of "stderr" in error_log.
Vladimir Homutov [Tue, 4 Jun 2013 07:27:36 +0000 (11:27 +0400)]
Core: fixed handling of "stderr" in error_log.

If "stderr" was specified in one of the "error_log" directives,
stderr is not redirected to the first error_log on startup,
configuration reload, and reopening log files.

12 years agoCore: fixed stderr redirection on win32 in ngx_reopen_files().
Vladimir Homutov [Mon, 3 Jun 2013 12:54:28 +0000 (16:54 +0400)]
Core: fixed stderr redirection on win32 in ngx_reopen_files().

On win32 stderr was not redirected into a file specified by "error_log"
while reopening files.  Fix is to use platform-independent functions to
work with stderr, as already used by ngx_init_cycle() and main() since
rev. d8316f307b6a.

12 years agorelease-1.5.1 tag
Maxim Dounin [Tue, 4 Jun 2013 13:21:52 +0000 (17:21 +0400)]
release-1.5.1 tag

12 years agonginx-1.5.1-RELEASE release-1.5.1
Maxim Dounin [Tue, 4 Jun 2013 13:21:52 +0000 (17:21 +0400)]
nginx-1.5.1-RELEASE

12 years agoUpdated zlib used for win32 builds.
Maxim Dounin [Tue, 4 Jun 2013 12:16:51 +0000 (16:16 +0400)]
Updated zlib used for win32 builds.

12 years agoWin32: accept_mutex now always disabled (ticket #362).
Maxim Dounin [Fri, 31 May 2013 10:59:26 +0000 (14:59 +0400)]
Win32: accept_mutex now always disabled (ticket #362).

Use of accept mutex on win32 may result in a deadlock if there are multiple
worker_processes configured and the mutex is grabbed by a process which
can't accept connections.

12 years agoOCSP stapling: fixed incorrect debug level.
Ruslan Ermilov [Fri, 31 May 2013 09:30:37 +0000 (13:30 +0400)]
OCSP stapling: fixed incorrect debug level.

12 years agoAccess: support for UNIX-domain client addresses (ticket #359).
Ruslan Ermilov [Thu, 30 May 2013 14:23:05 +0000 (18:23 +0400)]
Access: support for UNIX-domain client addresses (ticket #359).

12 years agoWin32: added missing reset of wev->ready on WSAEWOULDBLOCK.
Maxim Dounin [Wed, 29 May 2013 15:18:22 +0000 (19:18 +0400)]
Win32: added missing reset of wev->ready on WSAEWOULDBLOCK.

This fixes connection hang with websockets proxy, and likely some other
places as well.

12 years agoUpstream: http_403 support in proxy_next_upstream (and friends).
Maxim Dounin [Mon, 27 May 2013 12:54:09 +0000 (16:54 +0400)]
Upstream: http_403 support in proxy_next_upstream (and friends).

The parameter is mostly identical to http_404, and is expected to
be used in similar situations.  The 403 code might be returned by
a backend instead of 404 on initial sync of new directories with rsync.

See here for feature request and additional details:
http://mailman.nginx.org/pipermail/nginx-ru/2013-April/050920.html

12 years agoXslt: xslt_last_modified directive.
Maxim Dounin [Fri, 24 May 2013 18:28:09 +0000 (22:28 +0400)]
Xslt: xslt_last_modified directive.

Directive is similar to ssi_last_modified and sub_filter_last_modified
directives introduced by previous commits.

12 years agoSub filter: sub_filter_last_modified directive.
Maxim Dounin [Fri, 24 May 2013 18:27:30 +0000 (22:27 +0400)]
Sub filter: sub_filter_last_modified directive.

Directive is similar to ssi_last_modified introduced by previous commit.

Patch by Alexey Kolpakov.

12 years agoSSI: ssi_last_modified directive.
Maxim Dounin [Fri, 24 May 2013 18:27:23 +0000 (22:27 +0400)]
SSI: ssi_last_modified directive.

The "ssi_last_modified" directive allows to preserve Last-Modified header
in SSI responses.  The directive is similar to SSILastModified one available
in Apache:

http://httpd.apache.org/docs/2.4/mod/mod_include.html#ssilastmodified

Patch by Alexey Kolpakov.

12 years agoCore: strengthen configuration syntax checker.
Valentin Bartenev [Thu, 23 May 2013 16:30:27 +0000 (20:30 +0400)]
Core: strengthen configuration syntax checker.

It is now a syntax error if tokens passed to a custom configuration
handler are terminated by "{".

The following incorrect configuration is now properly rejected:

  map $v $v2 {
      a b {
      c d {
      e f {
  }

12 years agoMemcached: stricten header validation.
Ruslan Ermilov [Thu, 23 May 2013 12:26:10 +0000 (16:26 +0400)]
Memcached: stricten header validation.

An invalid memcached reply that started with '\n' could cause
segmentation fault.

An invalid memcached reply "VALUE / 0 2\r?ok\r\nEND\r\n" was
considered as a valid response.

In addition, if memcached reports that the key was not found,
set u->headers_in.content_length_n to 0.  This ensures that
ngx_http_memcached_filter() will not be called while previous
code relied on always intercepting 404.  Initialization of
ctx->rest was moved to where it belongs.

12 years agoUse "void" for functions with empty parameter list.
Sergey Kandaurov [Thu, 23 May 2013 11:47:58 +0000 (15:47 +0400)]
Use "void" for functions with empty parameter list.

12 years agoConfigure: fixed test of OS X atomic(3).
Ruslan Ermilov [Thu, 23 May 2013 06:23:21 +0000 (10:23 +0400)]
Configure: fixed test of OS X atomic(3).

12 years agoStyle: replace SSL *ssl with ngx_ssl_conn_t *ssl_conn.
Piotr Sikora [Wed, 22 May 2013 01:45:07 +0000 (18:45 -0700)]
Style: replace SSL *ssl with ngx_ssl_conn_t *ssl_conn.

No functional changes.

Signed-off-by: Piotr Sikora <piotr@cloudflare.com>
12 years agoStyle: remove unnecessary references to HTTP from non-HTTP modules.
Piotr Sikora [Wed, 22 May 2013 01:43:43 +0000 (18:43 -0700)]
Style: remove unnecessary references to HTTP from non-HTTP modules.

No functional changes.

Signed-off-by: Piotr Sikora <piotr@cloudflare.com>
12 years agoReferer module: added $invalid_referer to variables hash.
Maxim Dounin [Wed, 22 May 2013 18:31:53 +0000 (22:31 +0400)]
Referer module: added $invalid_referer to variables hash.

This makes it accessible via dynamic lookup with ngx_http_get_variable()
from Perl, SSI, etc.

Patch by Yichun Zhang (agentzh).

12 years agoUpstream: fixed fail_timeout and max_fails > 1.
Maxim Dounin [Tue, 21 May 2013 17:47:50 +0000 (21:47 +0400)]
Upstream: fixed fail_timeout and max_fails > 1.

Due to peer->checked always set since rev. c90801720a0c (1.3.0)
by round-robin and least_conn balancers (ip_hash not affected),
the code in ngx_http_upstream_free_round_robin_peer() function
incorrectly reset peer->fails too often.

Reported by Dmitry Popov,
http://mailman.nginx.org/pipermail/nginx-devel/2013-May/003720.html

13 years agoMail: missing ngx_ssl_ecdh_curve() call.
F. da Silva [Fri, 10 May 2013 14:53:45 +0000 (16:53 +0200)]
Mail: missing ngx_ssl_ecdh_curve() call.

12 years agoFixed error logging.
Sergey Kandaurov [Tue, 21 May 2013 13:30:19 +0000 (17:30 +0400)]
Fixed error logging.

The provided argument list didn't follow a used format string.

12 years agoUpstream: slightly optimized ngx_http_upstream_process_header().
Ruslan Ermilov [Tue, 21 May 2013 08:54:27 +0000 (12:54 +0400)]
Upstream: slightly optimized ngx_http_upstream_process_header().

12 years agoUpstream: made the assignment more obvious.
Ruslan Ermilov [Tue, 21 May 2013 08:54:26 +0000 (12:54 +0400)]
Upstream: made the assignment more obvious.

No functional changes.

12 years agoOCSP stapling: fix error logging of successful OCSP responses.
Piotr Sikora [Thu, 16 May 2013 22:37:13 +0000 (15:37 -0700)]
OCSP stapling: fix error logging of successful OCSP responses.

Due to a bad argument list, nginx worker would crash (SIGSEGV) while
trying to log the fact that it received OCSP response with "revoked"
or "unknown" certificate status.

While there, fix similar (but non-crashing) error a few lines above.

Signed-off-by: Piotr Sikora <piotr@cloudflare.com>
13 years agoMail: removed surplus ngx_close_connection() call.
Filipe Da Silva [Thu, 9 May 2013 08:54:28 +0000 (10:54 +0200)]
Mail: removed surplus ngx_close_connection() call.

It is already called for a peer connection a few lines above.

13 years agoUpstream keepalive: slightly simplified code.
Ruslan Ermilov [Wed, 15 May 2013 11:04:49 +0000 (15:04 +0400)]
Upstream keepalive: slightly simplified code.

13 years agoRemoved vestiges of SVN.
Ruslan Ermilov [Thu, 25 Apr 2013 13:41:45 +0000 (17:41 +0400)]
Removed vestiges of SVN.

13 years agoProxy: clear script engine used to calculate lengths.
Maxim Dounin [Wed, 15 May 2013 08:23:44 +0000 (12:23 +0400)]
Proxy: clear script engine used to calculate lengths.

Previous code is believed to be safe, but might access uninitialized
memory (e.g., e->quote).

13 years agoFixed lingering_time check.
Maxim Dounin [Mon, 13 May 2013 13:39:45 +0000 (17:39 +0400)]
Fixed lingering_time check.

There are two significant changes in this patch:

1) The <= 0 comparison is done with a signed type.  This fixes the case
   of ngx_time() being larger than r->lingering_time.

2) Calculation of r->lingering_time - ngx_time() is now always done
   in the ngx_msec_t type.  This ensures the calculation is correct
   even if time_t is unsigned and differs in size from ngx_msec_t.

Thanks to Lanshun Zhou.

13 years agoUpstream: allow to intercept responses with status 300.
Ruslan Ermilov [Mon, 13 May 2013 10:10:22 +0000 (14:10 +0400)]
Upstream: allow to intercept responses with status 300.

This fixes an omission made in 9e7926763f87 where all 3XX statuses
were allowed for "error_page".

13 years agoPCRE: retain input pattern for all regular expressions.
Piotr Sikora [Thu, 2 May 2013 10:26:36 +0000 (03:26 -0700)]
PCRE: retain input pattern for all regular expressions.

Previously, input pattern was kept only for regular expressions
with named captures, which resulted in error log entries without
input pattern for PCRE errors that occured while processing
regular expressions without them.

Signed-off-by: Piotr Sikora <piotr@cloudflare.com>
13 years agoProxy: $proxy_internal_body_length fixed.
Maxim Dounin [Sat, 11 May 2013 17:12:24 +0000 (21:12 +0400)]
Proxy: $proxy_internal_body_length fixed.

The $proxy_internal_body_length value might change during request lifetime,
notably if proxy_set_body used, and use of a cached value might result in
incorrect upstream requests.

Patch by Lanshun Zhou.

13 years agoMp4: indentation and style, no functional changes.
Maxim Dounin [Sat, 11 May 2013 14:49:49 +0000 (18:49 +0400)]
Mp4: indentation and style, no functional changes.

13 years agoAdded r->limit_rate_after.
Maxim Dounin [Sat, 11 May 2013 14:49:42 +0000 (18:49 +0400)]
Added r->limit_rate_after.

As of now, it allows to better control bandwidth limiting from additional
modules.  It is also expected to be used to add variables support to
the limit_rate_after directive.

13 years agoFixed build with --with-mail_ssl_module.
Maxim Dounin [Sat, 11 May 2013 14:49:30 +0000 (18:49 +0400)]
Fixed build with --with-mail_ssl_module.

If nginx was compiled without --with-http_ssl_module, but with some
other module which uses OpenSSL (e.g. --with-mail_ssl_module), insufficient
preprocessor check resulted in build failure.  The problem was introduced
by e0a3714a36f8 (1.3.14).

Reported by Roman Arutyunyan.

13 years agoRequest body: fixed r->count increment on allocation failure.
Maxim Dounin [Sat, 11 May 2013 14:49:19 +0000 (18:49 +0400)]
Request body: fixed r->count increment on allocation failure.

13 years agoPerl: extra "return" removed.
Maxim Dounin [Sat, 11 May 2013 14:48:56 +0000 (18:48 +0400)]
Perl: extra "return" removed.

13 years agoVersion bump.
Maxim Dounin [Sat, 11 May 2013 14:43:28 +0000 (18:43 +0400)]
Version bump.

13 years agorelease-1.5.0 tag
Maxim Dounin [Mon, 6 May 2013 10:05:17 +0000 (14:05 +0400)]
release-1.5.0 tag

13 years agorelease-1.5.0-RELEASE release-1.5.0
Maxim Dounin [Mon, 6 May 2013 09:52:36 +0000 (13:52 +0400)]
release-1.5.0-RELEASE

13 years agoFixed chunk size parsing.
Maxim Dounin [Mon, 6 May 2013 10:03:24 +0000 (14:03 +0400)]
Fixed chunk size parsing.

13 years agoProxy: allocate $proxy_internal_body_length from request pool.
Ruslan Ermilov [Mon, 29 Apr 2013 14:58:58 +0000 (18:58 +0400)]
Proxy: allocate $proxy_internal_body_length from request pool.

13 years agoConfigure: fixed detection of newer Apple clang compilers.
Ruslan Ermilov [Mon, 29 Apr 2013 14:07:22 +0000 (18:07 +0400)]
Configure: fixed detection of newer Apple clang compilers.

13 years agoVersion bump.
Ruslan Ermilov [Mon, 29 Apr 2013 14:06:58 +0000 (18:06 +0400)]
Version bump.

13 years agorelease-1.4.0 tag
Maxim Dounin [Wed, 24 Apr 2013 13:59:45 +0000 (13:59 +0000)]
release-1.4.0 tag

13 years agonginx-1.4.0-RELEASE release-1.4.0
Maxim Dounin [Wed, 24 Apr 2013 13:59:34 +0000 (13:59 +0000)]
nginx-1.4.0-RELEASE

13 years agoVersion bump.
Maxim Dounin [Wed, 24 Apr 2013 13:03:43 +0000 (13:03 +0000)]
Version bump.

13 years agoSPDY: set NGX_TCP_NODELAY_DISABLED for fake connections.
Valentin Bartenev [Tue, 23 Apr 2013 10:15:49 +0000 (10:15 +0000)]
SPDY: set NGX_TCP_NODELAY_DISABLED for fake connections.

This is to avoid setting the TCP_NODELAY flag on SPDY socket in
ngx_http_upstream_send_response().  The latter works per request,
but in SPDY case it might affect other streams in connection.

13 years agoPerl: request body handling fixed.
Maxim Dounin [Tue, 23 Apr 2013 10:04:12 +0000 (10:04 +0000)]
Perl: request body handling fixed.

As of 1.3.9, chunked request body may be available with
r->headers_in.content_length_n <= 0.  Additionally, request body
may be in multiple buffers even if r->request_body_in_single_buf
was requested.

13 years agoConfigure: fixed perl Makefile generation (ticket #334).
Maxim Dounin [Fri, 19 Apr 2013 12:19:57 +0000 (12:19 +0000)]
Configure: fixed perl Makefile generation (ticket #334).

Dependancy tracking introduced in r5169 were not handled absolute path
names properly.  Absolute names might appear in CORE_DEPS if --with-openssl
or --with-pcre configure arguments are used to build OpenSSL/PCRE
libraries.

Additionally, revert part of r5169 to set NGX_INCS from Makefile
variables.  Makefile variables have $ngx_include_opt in them, which
might result in wrong include paths being used.  As a side effect,
this also restores build with --with-http_perl_module and --without-http
at the same time.

13 years agoConfigure: uniformly refer to libs when searching for md5 and sha1.
Ruslan Ermilov [Thu, 18 Apr 2013 14:26:08 +0000 (14:26 +0000)]
Configure: uniformly refer to libs when searching for md5 and sha1.

13 years agoVersion bump.
Ruslan Ermilov [Thu, 18 Apr 2013 14:16:44 +0000 (14:16 +0000)]
Version bump.

13 years agorelease-1.3.16 tag
Maxim Dounin [Tue, 16 Apr 2013 14:05:22 +0000 (14:05 +0000)]
release-1.3.16 tag

13 years agonginx-1.3.16-RELEASE release-1.3.16
Maxim Dounin [Tue, 16 Apr 2013 14:05:11 +0000 (14:05 +0000)]
nginx-1.3.16-RELEASE

13 years agoEvents: backout eventport changes (r5172) for now.
Maxim Dounin [Tue, 16 Apr 2013 12:58:03 +0000 (12:58 +0000)]
Events: backout eventport changes (r5172) for now.

Evenport method needs more work.  Changes in r5172, while being correct,
introduce various new regressions with current code.

13 years agoRequest body: only read body in main request (ticket #330).
Maxim Dounin [Tue, 16 Apr 2013 10:14:59 +0000 (10:14 +0000)]
Request body: only read body in main request (ticket #330).

Before 1.3.9 an attempt to read body in a subrequest only caused problems
if body wasn't already read or discarded in a main request.  Starting with
1.3.9 it might also cause problems if body was discarded by a main request
before subrequest start.

Fix is to just ignore attempts to read request body in a subrequest, which
looks like right thing to do anyway.

13 years agoUpstream: warn if multiple non-stackable balancers are installed.
Ruslan Ermilov [Fri, 12 Apr 2013 19:12:13 +0000 (19:12 +0000)]
Upstream: warn if multiple non-stackable balancers are installed.

13 years agoEvents: fixed typos in two previous commits.
Valentin Bartenev [Fri, 12 Apr 2013 17:31:08 +0000 (17:31 +0000)]
Events: fixed typos in two previous commits.

13 years agoEvents: handle only active events in eventport.
Valentin Bartenev [Fri, 12 Apr 2013 15:04:23 +0000 (15:04 +0000)]
Events: handle only active events in eventport.

We generate both read and write events if an error event was returned by
port_getn() without POLLIN/POLLOUT, but we should not try to handle inactive
events, they may even have no handler.

13 years agoEvents: protection from stale events in eventport and devpoll.
Valentin Bartenev [Fri, 12 Apr 2013 15:02:33 +0000 (15:02 +0000)]
Events: protection from stale events in eventport and devpoll.

Stale write event may happen if read and write events was reported both,
and processing of the read event closed descriptor.

In practice this might result in "sendfilev() failed (134: ..." or
"writev() failed (134: ..." errors when switching to next upstream server.

See report here:
http://mailman.nginx.org/pipermail/nginx/2013-April/038421.html

13 years agoUpstream: fixed $upstream_response_length without buffering.
Sergey Kandaurov [Thu, 11 Apr 2013 13:49:13 +0000 (13:49 +0000)]
Upstream: fixed $upstream_response_length without buffering.

Reported by Piotr Sikora.

13 years agoConfigure: fixed nginx.so rebuild (broken by r5145).
Maxim Dounin [Wed, 10 Apr 2013 17:07:44 +0000 (17:07 +0000)]
Configure: fixed nginx.so rebuild (broken by r5145).

To avoid further breaks it's now done properly, all the dependencies
are now passed to Makefile.PL.  While here, fixed include list passed to
Makefile.PL to use Makefile variables rather than a list expanded during
configure.

13 years agoUpstream: removed surplus ngx_resolve_name_done() call.
Valentin Bartenev [Thu, 4 Apr 2013 14:19:06 +0000 (14:19 +0000)]
Upstream: removed surplus ngx_resolve_name_done() call.

It will be called in ngx_http_upstream_finalize_request().

13 years agoLimit req: rate should be non-zero.
Valentin Bartenev [Wed, 3 Apr 2013 14:13:35 +0000 (14:13 +0000)]
Limit req: rate should be non-zero.

Specifying zero rate caused division by zero when calculating delays.

13 years agoPass PCRE_CASELESS to pcre_compile() for caseless matching.
Ruslan Ermilov [Fri, 29 Mar 2013 08:47:37 +0000 (08:47 +0000)]
Pass PCRE_CASELESS to pcre_compile() for caseless matching.

Previously, we sometimes passed constant value 1 that happens to
match PCRE_CASELESS and thus was harmless.

13 years agoConfigure: unified nginx version computation constructs.
Ruslan Ermilov [Thu, 28 Mar 2013 08:47:25 +0000 (08:47 +0000)]
Configure: unified nginx version computation constructs.

13 years agoSimplified nginx version maintenance.
Ruslan Ermilov [Thu, 28 Mar 2013 08:47:06 +0000 (08:47 +0000)]
Simplified nginx version maintenance.

It's no longer necessary to update src/http/modules/perl/nginx.pm
when version is bumped, as it's now derived from src/core/nginx.h.

13 years agoConfigure: fixed perl module make rules.
Ruslan Ermilov [Thu, 28 Mar 2013 08:46:42 +0000 (08:46 +0000)]
Configure: fixed perl module make rules.

Filename extension used for dynamically loaded perl modules isn't
necessarily ".so" (e.g., it's ".bundle" on Mac OS X).

This fixes "make" after "make" unnecessarily rebuilding perl module.

13 years agoConfigure: improved make dependencies for perl module.
Ruslan Ermilov [Thu, 28 Mar 2013 08:46:12 +0000 (08:46 +0000)]
Configure: improved make dependencies for perl module.

Added missing dependencies for perl module's Makefile.

Simplified dependencies for perl module nginx.so: it depends
on Makefile that in turn depends on other perl bits.

13 years agoConfigure: improved layout of the generated makefile.
Ruslan Ermilov [Thu, 28 Mar 2013 08:45:45 +0000 (08:45 +0000)]
Configure: improved layout of the generated makefile.

No functional changes.

13 years agoUpstream: fixed tcp_nodelay with connection upgrade (ticket #325).
Maxim Dounin [Wed, 27 Mar 2013 15:18:34 +0000 (15:18 +0000)]
Upstream: fixed tcp_nodelay with connection upgrade (ticket #325).

13 years agoEvent connect: don't penalize AF_INET6 connections.
Maxim Dounin [Wed, 27 Mar 2013 15:16:45 +0000 (15:16 +0000)]
Event connect: don't penalize AF_INET6 connections.

Problems with setsockopt(TCP_NODELAY) and setsockopt(TCP_NOPUSH), as well
as sendfile() syscall on Solaris, are specific to UNIX-domain sockets.
Other address families, i.e. AF_INET and AF_INET6, are fine.

13 years agoVersion bump.
Maxim Dounin [Wed, 27 Mar 2013 15:15:34 +0000 (15:15 +0000)]
Version bump.

13 years agorelease-1.3.15 tag
Maxim Dounin [Tue, 26 Mar 2013 13:03:14 +0000 (13:03 +0000)]
release-1.3.15 tag

13 years agonginx-1.3.15-RELEASE release-1.3.15
Maxim Dounin [Tue, 26 Mar 2013 13:03:02 +0000 (13:03 +0000)]
nginx-1.3.15-RELEASE

13 years agoUse NGX_FILE_ERROR for handling file operations errors.
Valentin Bartenev [Mon, 25 Mar 2013 15:49:11 +0000 (15:49 +0000)]
Use NGX_FILE_ERROR for handling file operations errors.

On Win32 platforms 0 is used to indicate errors in file operations, so
comparing against -1 is not portable.

This was not much of an issue in patched code, since only ngx_fd_info() test
is actually reachable on Win32 and in worst case it might result in bogus
error log entry.

Patch by Piotr Sikora.

13 years agoUpstream: removed rudiments of upstream connection caching.
Ruslan Ermilov [Mon, 25 Mar 2013 14:51:44 +0000 (14:51 +0000)]
Upstream: removed rudiments of upstream connection caching.

This functionality is now provided by ngx_http_upstream_keepalive_module.

13 years agoUpstream: removed sorting of upstream servers.
Ruslan Ermilov [Mon, 25 Mar 2013 13:41:30 +0000 (13:41 +0000)]
Upstream: removed sorting of upstream servers.

Sorting of upstream servers by their weights is not required by
current balancing algorithms.

This will likely change mapping to backends served by ip_hash
weighted upstreams.

13 years agoMail: IPv6 backends (ticket #323).
Ruslan Ermilov [Mon, 25 Mar 2013 13:38:59 +0000 (13:38 +0000)]
Mail: IPv6 backends (ticket #323).

13 years agoUpstream: removed double-free workarounds in peer.free() methods.
Ruslan Ermilov [Mon, 25 Mar 2013 13:16:55 +0000 (13:16 +0000)]
Upstream: removed double-free workarounds in peer.free() methods.

13 years agoUpstream: only call peer.free() if peer.get() selected a peer.
Ruslan Ermilov [Mon, 25 Mar 2013 13:14:49 +0000 (13:14 +0000)]
Upstream: only call peer.free() if peer.get() selected a peer.

13 years agoMisc: support for Mercurial repositories.
Maxim Dounin [Fri, 22 Mar 2013 15:47:18 +0000 (15:47 +0000)]
Misc: support for Mercurial repositories.