add preadv/pwritev syscall wrappers

This commit is contained in:
Rich Felker 2012-09-09 16:29:33 -04:00
commit ea544bfe80
3 changed files with 35 additions and 0 deletions

13
src/unistd/preadv.c Normal file
View file

@ -0,0 +1,13 @@
#define _GNU_SOURCE
#include <sys/uio.h>
#include <unistd.h>
#include "syscall.h"
#include "libc.h"
ssize_t preadv(int fd, const struct iovec *iov, int count, off_t ofs)
{
return syscall_cp(SYS_preadv, fd, iov, count,
(long)(ofs), (long)(ofs>>32));
}
LFS64(preadv);

13
src/unistd/pwritev.c Normal file
View file

@ -0,0 +1,13 @@
#define _GNU_SOURCE
#include <sys/uio.h>
#include <unistd.h>
#include "syscall.h"
#include "libc.h"
ssize_t pwritev(int fd, const struct iovec *iov, int count, off_t ofs)
{
return syscall_cp(SYS_pwritev, fd, iov, count,
(long)(ofs), (long)(ofs>>32));
}
LFS64(pwritev);