You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by bo...@apache.org on 2007/05/12 14:39:44 UTC
svn commit: r537402 - /apr/apr/trunk/file_io/unix/readwrite.c
Author: bojan
Date: Sat May 12 05:39:44 2007
New Revision: 537402
URL: http://svn.apache.org/viewvc?view=rev&rev=537402
Log:
Avoid compiler warning (rv only used if HAVE_WRITEV).
Modified:
apr/apr/trunk/file_io/unix/readwrite.c
Modified: apr/apr/trunk/file_io/unix/readwrite.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/file_io/unix/readwrite.c?view=diff&rev=537402&r1=537401&r2=537402
==============================================================================
--- apr/apr/trunk/file_io/unix/readwrite.c (original)
+++ apr/apr/trunk/file_io/unix/readwrite.c Sat May 12 05:39:44 2007
@@ -226,8 +226,8 @@
APR_DECLARE(apr_status_t) apr_file_writev(apr_file_t *thefile, const struct iovec *vec,
apr_size_t nvec, apr_size_t *nbytes)
{
- apr_status_t rv;
#ifdef HAVE_WRITEV
+ apr_status_t rv;
apr_ssize_t bytes;
file_lock(thefile);
@@ -242,7 +242,8 @@
/* Position file pointer for writing at the offset we are
* logically reading from
*/
- apr_int64_t offset = thefile->filePtr - thefile->dataRead + thefile->bufpos;
+ apr_int64_t offset = thefile->filePtr - thefile->dataRead +
+ thefile->bufpos;
if (offset != thefile->filePtr)
lseek(thefile->filedes, offset, SEEK_SET);
thefile->bufpos = thefile->dataRead = 0;