Implemented setup of buffer flags so nginx knows where to read the file

from.
pull/4/head
Adrian Perez 2007-09-05 15:47:22 +02:00
parent a9a8ced810
commit a530ef1cd8
1 changed files with 8 additions and 0 deletions

View File

@ -63,6 +63,14 @@ ngx_buf_t* nfi_inline_getbuf(ngx_http_request_t *r,
if (buf == NULL)
return NULL;
/*
* ngx_pcalloc() makes zeros, which are good defaults for most values, we
* tell nginx that the file is on-disk, not in memory, and we associate
* the corresponding file information (ngx_file_t) structure.
*/
buf->file = bfile;
buf->in_file = 1;
return buf;
}