Mercurial > hg > nginx
changeset 2246:987831d73bd8
cache directio flag in open file cache
author | Igor Sysoev <igor@sysoev.ru> |
---|---|
date | Fri, 12 Sep 2008 13:39:51 +0000 |
parents | 8a98616abb73 |
children | 981483d63e9f |
files | src/core/ngx_open_file_cache.c src/core/ngx_open_file_cache.h |
diffstat | 2 files changed, 5 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/core/ngx_open_file_cache.c Thu Sep 11 15:52:11 2008 +0000 +++ b/src/core/ngx_open_file_cache.c Fri Sep 12 13:39:51 2008 +0000 @@ -205,6 +205,7 @@ of->is_file = file->is_file; of->is_link = file->is_link; of->is_exec = file->is_exec; + of->is_directio = file->is_directio; if (!file->is_dir) { file->count++; @@ -360,6 +361,7 @@ file->is_file = of->is_file; file->is_link = of->is_link; file->is_exec = of->is_exec; + file->is_directio = of->is_directio; if (!of->is_dir) { file->count++; @@ -499,9 +501,9 @@ of->fd = fd; if (of->directio <= ngx_file_size(&fi)) { - if (ngx_directio(fd) == -1) { + if (ngx_directio_on(fd) == -1) { ngx_log_error(NGX_LOG_ALERT, log, ngx_errno, - ngx_directio_n " \"%s\" failed", name); + ngx_directio_on_n " \"%s\" failed", name); } else { of->is_directio = 1;