diff options
author | Junio C Hamano <gitster@pobox.com> | 2013-09-09 14:50:39 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-09-09 14:50:39 -0700 |
commit | a23274e127fdb1674361271f14f7269f0a019cc2 (patch) | |
tree | ced6c65604f7d505718cc282d4797ec657c083c4 /compat | |
parent | Merge branch 'tg/index-struct-sizes' (diff) | |
parent | Revert "compat/clipped-write.c: large write(2) fails on Mac OS X/XNU" (diff) | |
download | tgif-a23274e127fdb1674361271f14f7269f0a019cc2.tar.xz |
Merge branch 'sp/clip-read-write-to-8mb'
Send a large request to read(2)/write(2) as a smaller but still
reasonably large chunks, which would improve the latency when the
operation needs to be killed and incidentally works around broken
64-bit systems that cannot take a 2GB write or read in one go.
* sp/clip-read-write-to-8mb:
Revert "compat/clipped-write.c: large write(2) fails on Mac OS X/XNU"
xread, xwrite: limit size of IO to 8MB
Diffstat (limited to 'compat')
-rw-r--r-- | compat/clipped-write.c | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/compat/clipped-write.c b/compat/clipped-write.c deleted file mode 100644 index b8f98ff77f..0000000000 --- a/compat/clipped-write.c +++ /dev/null @@ -1,13 +0,0 @@ -#include "../git-compat-util.h" -#undef write - -/* - * Version of write that will write at most INT_MAX bytes. - * Workaround a xnu bug on Mac OS X - */ -ssize_t clipped_write(int fildes, const void *buf, size_t nbyte) -{ - if (nbyte > INT_MAX) - nbyte = INT_MAX; - return write(fildes, buf, nbyte); -} |