diff options
author | Junio C Hamano <gitster@pobox.com> | 2013-06-03 00:54:54 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-06-03 00:54:54 +0200 |
commit | 29d5350c0115d8847d010830b0dcca429b038e31 (patch) | |
tree | 598980e3e9e7265abb7292849420292e43244ac8 /git-compat-util.h | |
parent | Merge branch 'vv/help-unknown-ref' (diff) | |
parent | compate/clipped-write.c: large write(2) fails on Mac OS X/XNU (diff) | |
download | git-29d5350c0115d8847d010830b0dcca429b038e31.tar.xz git-29d5350c0115d8847d010830b0dcca429b038e31.zip |
Merge branch 'fc/macos-x-clipped-write'
Mac OS X does not like to write(2) more than INT_MAX number of
bytes.
* fc/macos-x-clipped-write:
compate/clipped-write.c: large write(2) fails on Mac OS X/XNU
Diffstat (limited to 'git-compat-util.h')
-rw-r--r-- | git-compat-util.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/git-compat-util.h b/git-compat-util.h index c1f8a477fb..660b7f012a 100644 --- a/git-compat-util.h +++ b/git-compat-util.h @@ -185,6 +185,11 @@ int get_st_mode_bits(const char *path, int *mode); #define probe_utf8_pathname_composition(a,b) #endif +#ifdef NEEDS_CLIPPED_WRITE +ssize_t clipped_write(int fildes, const void *buf, size_t nbyte); +#define write(x,y,z) clipped_write((x),(y),(z)) +#endif + #ifdef MKDIR_WO_TRAILING_SLASH #define mkdir(a,b) compat_mkdir_wo_trailing_slash((a),(b)) extern int compat_mkdir_wo_trailing_slash(const char*, mode_t); |