Upstream: u->length now defaults to -1 (API change).
That is, by default we assume that response end is signalled by
a connection close. This seems to be better default, and in line
with u->pipe->length behaviour.
Memcached module was modified accordingly.
Maxim Dounin
8 years ago
440 | 440 | u = ctx->request->upstream; |
441 | 441 | |
442 | 442 | if (u->headers_in.status_n != 404) { |
443 | u->length += NGX_HTTP_MEMCACHED_END; | |
443 | u->length = u->headers_in.content_length_n + NGX_HTTP_MEMCACHED_END; | |
444 | 444 | ctx->rest = NGX_HTTP_MEMCACHED_END; |
445 | ||
446 | } else { | |
447 | u->length = 0; | |
445 | 448 | } |
446 | 449 | |
447 | 450 | return NGX_OK; |