Mercurial > hg > nginx
comparison src/core/ngx_output_chain.c @ 7949:862f6130d357
Upstream: sendfile_max_chunk support.
Previously, connections to upstream servers used sendfile() if it was
enabled, but never honored sendfile_max_chunk. This might result
in worker monopolization for a long time if large request bodies
are allowed.
author | Maxim Dounin <mdounin@mdounin.ru> |
---|---|
date | Fri, 29 Oct 2021 20:21:54 +0300 |
parents | a7ff19afbb14 |
children | ec2e6893caaa |
comparison
equal
deleted
inserted
replaced
7948:a2613fc1bce5 | 7949:862f6130d357 |
---|---|
801 | 801 |
802 if (chain == NGX_CHAIN_ERROR) { | 802 if (chain == NGX_CHAIN_ERROR) { |
803 return NGX_ERROR; | 803 return NGX_ERROR; |
804 } | 804 } |
805 | 805 |
806 if (chain && c->write->ready) { | |
807 ngx_post_event(c->write, &ngx_posted_next_events); | |
808 } | |
809 | |
806 for (cl = ctx->out; cl && cl != chain; /* void */) { | 810 for (cl = ctx->out; cl && cl != chain; /* void */) { |
807 ln = cl; | 811 ln = cl; |
808 cl = cl->next; | 812 cl = cl->next; |
809 ngx_free_chain(ctx->pool, ln); | 813 ngx_free_chain(ctx->pool, ln); |
810 } | 814 } |