summaryrefslogtreecommitdiff
path: root/git-compat-util.h
Commit message (Collapse)AuthorAgeFilesLines
* ?alloc: do not return NULL when asked for zero bytesJunio C Hamano2005-12-291-0/+6
| | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* xread/xwrite: do not worry about EINTR at calling sites.Junio C Hamano2005-12-191-0/+22
| | | | | | | | | | We had errno==EINTR check after read(2)/write(2) sprinkled all over the places, always doing continue. Consolidate them into xread()/xwrite() wrapper routines. Credits for suggestion goes to HPA -- bugs are mine. Signed-off-by: Junio C Hamano <junkio@cox.net>
* define MAXPATHLEN for hosts that don't support itMartin Atukunda2005-12-141-0/+3
| | | | | | [jc: Martin says syllable (www.syllable.org) wants this.] Signed-off-by: Junio C Hamano <junkio@cox.net>
* Clean up compatibility definitions.Junio C Hamano2005-12-051-0/+113
This attempts to clean up the way various compatibility functions are defined and used. - A new header file, git-compat-util.h, is introduced. This looks at various NO_XXX and does necessary function name replacements, equivalent of -Dstrcasestr=gitstrcasestr in the Makefile. - Those function name replacements are removed from the Makefile. - Common features such as usage(), die(), xmalloc() are moved from cache.h to git-compat-util.h; cache.h includes git-compat-util.h itself. Signed-off-by: Junio C Hamano <junkio@cox.net>