home *** CD-ROM | disk | FTP | other *** search
/ RISCWORLD 7 / RISCWORLD_VOL7.iso / Software / Issue6 / SDL.ZIP / !gcc / include / unixlib / sys / h / uio < prev    next >
Encoding:
Text File  |  2006-09-17  |  1.2 KB  |  47 lines

  1. /****************************************************************************
  2.  *
  3.  * $Source: /usr/local/cvsroot/gccsdk/unixlib/source/clib/sys/uio.h,v $
  4.  * $Date: 2004/04/17 10:51:15 $
  5.  * $Revision: 1.6 $
  6.  * $State: Exp $
  7.  * $Author: nick $
  8.  *
  9.  ***************************************************************************/
  10.  
  11. #ifndef __SYS_UIO_H
  12. #define __SYS_UIO_H 1
  13.  
  14. #ifndef __UNIXLIB_FEATURES_H
  15. #include <features.h>
  16. #endif
  17.  
  18. #include <sys/types.h>
  19.  
  20. __BEGIN_DECLS
  21.  
  22. /* Structure describing a section of memory.  */
  23.  
  24. struct iovec
  25. {
  26.   /* Starting address.  */
  27.   void *iov_base;
  28.   /* Length in bytes.  */
  29.   size_t iov_len;
  30. };
  31.  
  32. /* Read data from file descriptor FD, and put the result in the
  33.    buffers described by VECTOR, which is a vector of COUNT `struct iovec's.
  34.    The buffers are filled in the order specified.  */
  35. extern ssize_t readv (int __fd, const struct iovec * __vector,
  36.               int __count) __THROW;
  37.  
  38. /* Write data pointed by the buffers described by VECTOR, which
  39.    is a vector of COUNT `struct iovec's, to file descriptor FD.
  40.    The data is written in the order specified. */
  41. extern ssize_t writev (int __fd, const struct iovec * __vector,
  42.                int __count) __THROW;
  43.  
  44. __END_DECLS
  45.  
  46. #endif
  47.