summaryrefslogtreecommitdiff
path: root/file_io/unix/readwrite.c
diff options
context:
space:
mode:
authorpquerna <pquerna@13f79535-47bb-0310-9956-ffa450edef68>2004-12-05 02:17:30 +0000
committerpquerna <pquerna@13f79535-47bb-0310-9956-ffa450edef68>2004-12-05 02:17:30 +0000
commitb4f4f12975476cc57b8163abe0bcf937b83330f5 (patch)
tree6eb56cab80b162bb7728ad44750c68a8300fed53 /file_io/unix/readwrite.c
parent6ce9594ae922941baa68b477f279d4c67c0937ab (diff)
downloadlibapr-b4f4f12975476cc57b8163abe0bcf937b83330f5.tar.gz
* file_io/unix/fullrw.c: Add apr_file_writev_full to ensure an iovec is
completely written to the file. * include/apr_file_io.h: Define APR_MAX_IOVEC_SIZE Add public def for apr_file_writev_full. * file_io/unix/readwrite.c: For systems without writev, ensure that they get the correct number of bytes written. * test/*: Add a new test for apr_file_writev_full. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@109843 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'file_io/unix/readwrite.c')
-rw-r--r--file_io/unix/readwrite.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/file_io/unix/readwrite.c b/file_io/unix/readwrite.c
index edd692e4b..069adfa96 100644
--- a/file_io/unix/readwrite.c
+++ b/file_io/unix/readwrite.c
@@ -244,6 +244,8 @@ APR_DECLARE(apr_status_t) apr_file_writev(apr_file_t *thefile, const struct iove
int i, tbytes;
apr_status_t rv = APR_SUCCESS;
+ *nbytes = 0;
+
for(i = 0; i < nvec; i++){
tbytes = vec[i].iov_len;
rv = apr_file_write(thefile, vec[i].iov_base, &tbytes);