aboutsummaryrefslogtreecommitdiff
path: root/src/os/unix/ngx_files.c
diff options
context:
space:
mode:
authorMaxim Dounin <mdounin@mdounin.ru>2012-11-26 21:19:57 +0000
committerMaxim Dounin <mdounin@mdounin.ru>2012-11-26 21:19:57 +0000
commit1469b5145142ba2096e7c3467e867e8bf67cab25 (patch)
treec6e0d8740cb6e0d21f52a478c0cc87b1140be5b5 /src/os/unix/ngx_files.c
parente769544a7dc54e224fa0ef681c36ede12f65d74b (diff)
downloadnginx-1469b5145142ba2096e7c3467e867e8bf67cab25.tar.gz
nginx-1469b5145142ba2096e7c3467e867e8bf67cab25.zip
Core: fixed ngx_write_chain_to_file() with IOV_MAX reached.
Catched by dav_chunked.t on Solaris. In released versions this might potentially result in corruption of complex protocol responses if they were written to disk and there were more distinct buffers than IOV_MAX in a single write.
Diffstat (limited to 'src/os/unix/ngx_files.c')
-rw-r--r--src/os/unix/ngx_files.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/os/unix/ngx_files.c b/src/os/unix/ngx_files.c
index 65d2320b2..4fdf884fc 100644
--- a/src/os/unix/ngx_files.c
+++ b/src/os/unix/ngx_files.c
@@ -246,6 +246,7 @@ ngx_write_chain_to_file(ngx_file_t *file, ngx_chain_t *cl, off_t offset,
file->sys_offset += n;
file->offset += n;
+ offset += n;
total += n;
} while (cl);