Mercurial > hg > nginx
comparison src/event/ngx_event_proxy.c @ 140:e32405df0e77
nginx-0.0.1-2003-10-08-08:34:07 import
author | Igor Sysoev <igor@sysoev.ru> |
---|---|
date | Wed, 08 Oct 2003 04:34:07 +0000 |
parents | 54307053f185 |
children | 5526213be452 |
comparison
equal
deleted
inserted
replaced
139:54307053f185 | 140:e32405df0e77 |
---|---|
7 | 7 |
8 #define NGX_EVENT_COPY_FILTER 0 | 8 #define NGX_EVENT_COPY_FILTER 0 |
9 | 9 |
10 #if (NGX_EVENT_COPY_FILTER) | 10 #if (NGX_EVENT_COPY_FILTER) |
11 static int ngx_event_proxy_copy_input_filter(ngx_event_proxy_t *p, | 11 static int ngx_event_proxy_copy_input_filter(ngx_event_proxy_t *p, |
12 ngx_chain_t *chain); | 12 ngx_chain_t *chain); |
13 #endif | 13 #endif |
14 | 14 |
15 | 15 |
16 | 16 |
17 int ngx_event_proxy_read_upstream(ngx_event_proxy_t *p) | 17 int ngx_event_proxy_read_upstream(ngx_event_proxy_t *p) |
107 p->file_hunks = NULL; | 107 p->file_hunks = NULL; |
108 | 108 |
109 ngx_log_debug(p->log, "file hunk: %08X" _ chain->hunk _ | 109 ngx_log_debug(p->log, "file hunk: %08X" _ chain->hunk _ |
110 chain->hunk->end - chain->hunk->last); | 110 chain->hunk->end - chain->hunk->last); |
111 | 111 |
112 /* if the hunks is not needed to be saved in a cache and | 112 /* if the hunks are not needed to be saved in a cache and |
113 a downstream is ready then write the hunks to a downstream */ | 113 a downstream is ready then write the hunks to a downstream */ |
114 | 114 |
115 } else if (p->cachable == 0 && p->downstream->write->ready) { | 115 } else if (p->cachable == 0 && p->downstream->write->ready) { |
116 | 116 |
117 ngx_log_debug(p->log, "downstream ready"); | 117 ngx_log_debug(p->log, "downstream ready"); |
707 #if (NGX_EVENT_COPY_FILTER) | 707 #if (NGX_EVENT_COPY_FILTER) |
708 | 708 |
709 /* the copy input filter */ | 709 /* the copy input filter */ |
710 | 710 |
711 static int ngx_event_proxy_copy_input_filter(ngx_event_proxy_t *p, | 711 static int ngx_event_proxy_copy_input_filter(ngx_event_proxy_t *p, |
712 ngx_chain_t *chain) | 712 ngx_chain_t *chain) |
713 { | 713 { |
714 ngx_hunk_t *h; | 714 ngx_hunk_t *h; |
715 ngx_chain_t *entry, *temp; | 715 ngx_chain_t *entry, *temp; |
716 | 716 |
717 if (p->upstream_eof) { | 717 if (p->upstream_eof) { |