Commit 08c318db authored by Genevieve Helsel's avatar Genevieve Helsel Committed by Facebook Github Bot

add pwritevNoInt and preadvNoInt to FileUtil

Summary: Adds `pwritevNoInt()` and `preadvNoInt()` to FileUtil.

Reviewed By: yfeldblum

Differential Revision: D18213230

fbshipit-source-id: 0dfcd19ecf4500aa2bba279800d65821309371c6
parent 82ca15c5
......@@ -111,6 +111,10 @@ ssize_t readvNoInt(int fd, const iovec* iov, int count) {
return wrapNoInt(readv, fd, iov, count);
}
ssize_t preadvNoInt(int fd, const iovec* iov, int count, off_t offset) {
return wrapNoInt(preadv, fd, iov, count, offset);
}
ssize_t writeNoInt(int fd, const void* buf, size_t count) {
return wrapNoInt(write, fd, buf, count);
}
......@@ -123,6 +127,10 @@ ssize_t writevNoInt(int fd, const iovec* iov, int count) {
return wrapNoInt(writev, fd, iov, count);
}
ssize_t pwritevNoInt(int fd, const iovec* iov, int count, off_t offset) {
return wrapNoInt(pwritev, fd, iov, count, offset);
}
ssize_t readFull(int fd, void* buf, size_t count) {
return wrapFull(read, fd, buf, count);
}
......
......@@ -54,10 +54,12 @@ int shutdownNoInt(NetworkSocket fd, int how);
ssize_t readNoInt(int fd, void* buf, size_t n);
ssize_t preadNoInt(int fd, void* buf, size_t n, off_t offset);
ssize_t readvNoInt(int fd, const iovec* iov, int count);
ssize_t preadvNoInt(int fd, const iovec* iov, int count, off_t offset);
ssize_t writeNoInt(int fd, const void* buf, size_t n);
ssize_t pwriteNoInt(int fd, const void* buf, size_t n, off_t offset);
ssize_t writevNoInt(int fd, const iovec* iov, int count);
ssize_t pwritevNoInt(int fd, const iovec* iov, int count, off_t offset);
/**
* Wrapper around read() (and pread()) that, in addition to retrying on
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment