You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by dr...@locus.apache.org on 2000/03/02 13:51:09 UTC
cvs commit: apache-2.0/src/lib/apr/file_io/unix readwrite.c
dreid 00/03/02 04:51:08
Modified: src/lib/apr/file_io/beos readwrite.c
src/lib/apr/file_io/unix readwrite.c
Log:
Bring BeOS ap_writev up to date and amend the documentation to show
the new argumnets.
Revision Changes Path
1.8 +10 -11 apache-2.0/src/lib/apr/file_io/beos/readwrite.c
Index: readwrite.c
===================================================================
RCS file: /home/cvs/apache-2.0/src/lib/apr/file_io/beos/readwrite.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- readwrite.c 2000/02/21 16:41:39 1.7
+++ readwrite.c 2000/03/02 12:51:08 1.8
@@ -127,30 +127,29 @@
}
/* ***APRDOC********************************************************
- * ap_status_t ap_writev(ap_file_t *, iovec *, ap_ssize_t *)
- * Write data from ap_iovec array to the specified file.
+ * ap_status_t ap_writev(ap_file_t *, struct iovec *, ap_size_t, ap_ssize_t *)
+ * Write data from iovec array to the specified file.
* arg 1) The file descriptor to write to.
* arg 2) The array from which to get the data to write to the file.
- * arg 3) The number of elements in the ap_iovec array. This must be
+ * arg 3) The number of elements in the struct iovec array. This must be
* smaller than AP_MAX_IOVEC_SIZE. If it isn't, the function will
* fail with APR_EINVAL.
- * NOTE: The third arguement is updated with the number of bytes actually
- * written on function exit.
+ * arg 4) The number of bytes written.
*/
-#ifdef HAVE_WRITEV
-ap_status_t ap_writev(struct file_t *thefile, const struct iovec *vec, ap_ssize_t *iocnt)
+
+ap_status_t ap_writev(struct file_t *thefile, const struct iovec *vec,
+ ap_size_t nvec, ap_ssize_t *nbytes)
{
int bytes;
- if ((bytes = writev(thefile->filedes, vec, *iocnt)) < 0) {
- *iocnt = bytes;
+ if ((bytes = writev(thefile->filedes, vec, nvec)) < 0) {
+ *nbytes = 0;
return errno;
}
else {
- *iocnt = bytes;
+ *nbytes = bytes;
return APR_SUCCESS;
}
}
-#endif
/* ***APRDOC********************************************************
* ap_status_t ap_putc(char, ap_file_t *)
1.23 +3 -4 apache-2.0/src/lib/apr/file_io/unix/readwrite.c
Index: readwrite.c
===================================================================
RCS file: /home/cvs/apache-2.0/src/lib/apr/file_io/unix/readwrite.c,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -r1.22 -r1.23
--- readwrite.c 2000/03/01 16:21:14 1.22
+++ readwrite.c 2000/03/02 12:51:08 1.23
@@ -205,15 +205,14 @@
}
/* ***APRDOC********************************************************
- * ap_status_t ap_writev(ap_file_t *, struct iovec *, ap_ssize_t *)
+ * ap_status_t ap_writev(ap_file_t *, struct iovec *, ap_size_t, ap_ssize_t *)
* Write data from iovec array to the specified file.
* arg 1) The file descriptor to write to.
* arg 2) The array from which to get the data to write to the file.
- * arg 3) The number of elements in the struct iovec array. This must be
+ * arg 3) The number of elements in the struct iovec array. This must be
* smaller than AP_MAX_IOVEC_SIZE. If it isn't, the function will
* fail with APR_EINVAL.
- * NOTE: The third arguement is updated with the number of bytes actually
- * written on function exit.
+ * arg 4) The number of bytes written.
*/
#ifdef HAVE_WRITEV
ap_status_t ap_writev(struct file_t *thefile, const struct iovec *vec,
Re: cvs commit: apache-2.0/src/lib/apr/file_io/unix readwrite.c
Posted by David Reid <dr...@jetnet.co.uk>.
Yeah, they should all be in the unix files, but I think I was being lazy the
day I copied readwrite.c...
:)
----- Original Message -----
From: <rb...@apache.org>
To: <ap...@apache.org>
Sent: Thursday, March 02, 2000 8:39 PM
Subject: Re: cvs commit: apache-2.0/src/lib/apr/file_io/unix readwrite.c
> On Thu, 2 Mar 2000, Greg Stein wrote:
>
> > On Thu, 2 Mar 2000, Dean Gaudet wrote:
> > > On 2 Mar 2000 dreid@locus.apache.org wrote:
> > >
> > > > dreid 00/03/02 04:51:08
> > > >
> > > > Modified: src/lib/apr/file_io/beos readwrite.c
> > > > src/lib/apr/file_io/unix readwrite.c
> > > > Log:
> > > > Bring BeOS ap_writev up to date and amend the documentation to
show
> > > > the new argumnets.
> > >
> > > hmm, does someone feel like moving the documentation to the common
include
> > > files rather than having it duplicated across each os .c file?
> >
> > +1
>
> I have no problem with having the docs moved to the include files, but I
> would mention that they aren't spread across ox .c files. The docs are
> all in the unix .c files.
>
> Ryan
>
> Come to the first official Apache Software Foundation
> Conference!!! <http://ApacheCon.Com/>
>
>
____________________________________________________________________________
___
> Ryan Bloom rbb@apache.org
> 406 29th St.
> San Francisco, CA 94131
> --------------------------------------------------------------------------
-----
>
>
Re: cvs commit: apache-2.0/src/lib/apr/file_io/unix readwrite.c
Posted by rb...@apache.org.
On Thu, 2 Mar 2000, Greg Stein wrote:
> On Thu, 2 Mar 2000, Dean Gaudet wrote:
> > On 2 Mar 2000 dreid@locus.apache.org wrote:
> >
> > > dreid 00/03/02 04:51:08
> > >
> > > Modified: src/lib/apr/file_io/beos readwrite.c
> > > src/lib/apr/file_io/unix readwrite.c
> > > Log:
> > > Bring BeOS ap_writev up to date and amend the documentation to show
> > > the new argumnets.
> >
> > hmm, does someone feel like moving the documentation to the common include
> > files rather than having it duplicated across each os .c file?
>
> +1
I have no problem with having the docs moved to the include files, but I
would mention that they aren't spread across ox .c files. The docs are
all in the unix .c files.
Ryan
Come to the first official Apache Software Foundation
Conference!!! <http://ApacheCon.Com/>
_______________________________________________________________________________
Ryan Bloom rbb@apache.org
406 29th St.
San Francisco, CA 94131
-------------------------------------------------------------------------------
Re: cvs commit: apache-2.0/src/lib/apr/file_io/unix readwrite.c
Posted by Greg Stein <gs...@lyra.org>.
On Thu, 2 Mar 2000, Dean Gaudet wrote:
> On 2 Mar 2000 dreid@locus.apache.org wrote:
>
> > dreid 00/03/02 04:51:08
> >
> > Modified: src/lib/apr/file_io/beos readwrite.c
> > src/lib/apr/file_io/unix readwrite.c
> > Log:
> > Bring BeOS ap_writev up to date and amend the documentation to show
> > the new argumnets.
>
> hmm, does someone feel like moving the documentation to the common include
> files rather than having it duplicated across each os .c file?
+1
--
Greg Stein, http://www.lyra.org/
Re: cvs commit: apache-2.0/src/lib/apr/file_io/unix readwrite.c
Posted by Dean Gaudet <dg...@arctic.org>.
On 2 Mar 2000 dreid@locus.apache.org wrote:
> dreid 00/03/02 04:51:08
>
> Modified: src/lib/apr/file_io/beos readwrite.c
> src/lib/apr/file_io/unix readwrite.c
> Log:
> Bring BeOS ap_writev up to date and amend the documentation to show
> the new argumnets.
hmm, does someone feel like moving the documentation to the common include
files rather than having it duplicated across each os .c file?
Dean