diff options
| author | Dhruva Krishnamurthy <dhruvakm@gmail.com> | 2020-06-17 14:31:11 -0700 |
|---|---|---|
| committer | Dhruva Krishnamurthy <dhruvakm@gmail.com> | 2020-12-30 06:55:40 -0800 |
| commit | 4ce8e01a7ada3c75f7407dc9fafd25b4ac38d037 (patch) | |
| tree | 526cd9e3bf31ffd6e9fce4993b649ce2875713c4 /src/unix | |
| parent | a9f57a8919f264fa184320d1f5c3ed7a35b7576a (diff) | |
| download | libgit2-4ce8e01a7ada3c75f7407dc9fafd25b4ac38d037.tar.gz | |
Support build with NO_MMAP to disable use of system mmap
* Use pread/pwrite to avoid updating position in file descriptor
* Emulate missing pread/pwrite on win32 using overlapped file IO
Diffstat (limited to 'src/unix')
| -rw-r--r-- | src/unix/posix.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/unix/posix.h b/src/unix/posix.h index b5527a4a8..7b3325e78 100644 --- a/src/unix/posix.h +++ b/src/unix/posix.h @@ -101,4 +101,7 @@ GIT_INLINE(int) p_futimes(int f, const struct p_timeval t[2]) # define p_futimes futimes #endif +#define p_pread(f, d, s, o) pread(f, d, s, o) +#define p_pwrite(f, d, s, o) pwrite(f, d, s, o) + #endif |
