]> git.kaiwu.me - nginx.git/commitdiff
fix segfault if ngx_read_file() will fail
authorIgor Sysoev <igor@sysoev.ru>
Tue, 24 Mar 2009 15:03:38 +0000 (15:03 +0000)
committerIgor Sysoev <igor@sysoev.ru>
Tue, 24 Mar 2009 15:03:38 +0000 (15:03 +0000)
src/http/ngx_http_file_cache.c

index 80636487162063836fd4701cfca58eaa077454f9..1e80a39eedc5684f012c940b3eeacb56bc4cfebf 100644 (file)
@@ -251,6 +251,7 @@ ngx_http_file_cache_open(ngx_http_request_t *r)
                    "http file cache fd: %d", of.fd);
 
     c->file.fd = of.fd;
+    c->file.log = r->connection->log;
 
     c->buf = ngx_create_temp_buf(r->pool, c->body_start);
     if (c->buf == NULL) {