From cc90b1798ab70a49bfee713d35104965be22c701 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Axel=20D=C3=B6rfler?= Date: Wed, 1 Sep 2004 16:26:15 +0000 Subject: [PATCH] Removed unsupported cruft from uio.h (uiomove()). Made header C++ safe. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@8780 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- headers/posix/sys/uio.h | 33 ++++++++++++--------------------- 1 file changed, 12 insertions(+), 21 deletions(-) diff --git a/headers/posix/sys/uio.h b/headers/posix/sys/uio.h index 5f24dd2ae8..669a369694 100644 --- a/headers/posix/sys/uio.h +++ b/headers/posix/sys/uio.h @@ -1,39 +1,30 @@ -/* uio.h */ - #ifndef _SYS_UIO_H #define _SYS_UIO_H +/* +** Distributed under the terms of the Haiku License. +*/ + #include + typedef struct iovec { void *iov_base; size_t iov_len; } iovec; -enum uio_rw { UIO_READ, UIO_WRITE }; - -/* Segment flag values. */ -enum uio_seg { - UIO_USERSPACE, /* from user data space */ - UIO_SYSSPACE /* from system space */ -}; - -struct uio { - struct iovec *uio_iov; /* pointer to array of iovecs */ - int uio_iovcnt; /* number of iovecs in array */ - off_t uio_offset; /* offset into file this uio corresponds to */ - size_t uio_resid; /* residual i/o count */ - enum uio_seg uio_segflg; /* see above */ - enum uio_rw uio_rw; /* see above */ -// struct proc *uio_procp; /* process if UIO_USERSPACE */ -}; - -int uiomove(char *cp, int n, struct uio *uio); +#ifdef __cplusplus +extern "C" { +#endif ssize_t readv(int fd, const struct iovec *vector, size_t count); ssize_t readv_pos(int fd, off_t pos, const struct iovec *vec, size_t count); ssize_t writev(int fd, const struct iovec *vector, size_t count); ssize_t writev_pos(int fd, off_t pos, const struct iovec *vec, size_t count); +#ifdef __cplusplus +} +#endif + #endif /* _SYS_UIO_H */