diff options
| author | Igor Sysoev <igor@sysoev.ru> | 2010-07-28 15:49:34 +0000 |
|---|---|---|
| committer | Igor Sysoev <igor@sysoev.ru> | 2010-07-28 15:49:34 +0000 |
| commit | 406a68003cfc3b9907bd40699c4a51df4cee3a5a (patch) | |
| tree | 3375c5abfa5b609b71145b2bec2e918dc67b4aa9 /src/http/ngx_http_cache.h | |
| parent | 18b36e5035ec5b96fbc44311df5e5dd426d4e93e (diff) | |
| download | nginx-406a68003cfc3b9907bd40699c4a51df4cee3a5a.tar.gz nginx-406a68003cfc3b9907bd40699c4a51df4cee3a5a.tar.bz2 | |
several changes in cache cleanup handling:
*) now ngx_http_file_cache_cleanup() uses ngx_http_file_cache_free()
*) ngx_http_file_cache_free() interface has been changed to accept r->cache
ngx_http_file_cache_cleanup() must use r->cache, but not r, because
there can be several r->cache's during request processing, r->cache may
be NULL at request finalising, etc.
*) test if updating request does not complete correctly
Diffstat (limited to '')
| -rw-r--r-- | src/http/ngx_http_cache.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/http/ngx_http_cache.h b/src/http/ngx_http_cache.h index 36b14b26e..1a23e4620 100644 --- a/src/http/ngx_http_cache.h +++ b/src/http/ngx_http_cache.h @@ -78,6 +78,7 @@ struct ngx_http_cache_s { ngx_http_file_cache_node_t *node; unsigned updated:1; + unsigned updating:1; unsigned exists:1; unsigned temp_file:1; }; @@ -129,7 +130,7 @@ ngx_int_t ngx_http_file_cache_open(ngx_http_request_t *r); void ngx_http_file_cache_set_header(ngx_http_request_t *r, u_char *buf); void ngx_http_file_cache_update(ngx_http_request_t *r, ngx_temp_file_t *tf); ngx_int_t ngx_http_cache_send(ngx_http_request_t *); -void ngx_http_file_cache_free(ngx_http_request_t *r, ngx_temp_file_t *tf); +void ngx_http_file_cache_free(ngx_http_cache_t *c, ngx_temp_file_t *tf); time_t ngx_http_file_cache_valid(ngx_array_t *cache_valid, ngx_uint_t status); char *ngx_http_file_cache_set_slot(ngx_conf_t *cf, ngx_command_t *cmd, |
