Changeset 4507:e66122a62bde in nginx


Ignore:
Timestamp:
03/05/12 12:15:02 (8 years ago)
Author:
Maxim Dounin <mdounin@…>
Branch:
stable-1.0
Phase:
public
Convert:
svn:c3fe7df1-7212-e011-8a91-001109144009/branches/stable-1.0@4508
Message:

Merge of r4461: upstream: fixed "too big header" check.

If header filter postponed processing of a header by returning NGX_AGAIN
and not moved u->buffer->pos, previous check incorrectly assumed there
is additional space and did another recv() with zero-size buffer. This
resulted in "upstream prematurely closed connection" error instead
of correct "upstream sent too big header" one.

Patch by Feibo Li.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/http/ngx_http_upstream.c

    r4450 r4507  
    15621562        if (rc == NGX_AGAIN) {
    15631563
    1564             if (u->buffer.pos == u->buffer.end) {
     1564            if (u->buffer.last == u->buffer.end) {
    15651565                ngx_log_error(NGX_LOG_ERR, c->log, 0,
    15661566                              "upstream sent too big header");
Note: See TracChangeset for help on using the changeset viewer.