From: David Michael Date: Thu, 4 Dec 2014 02:24:17 +0000 (-0500) Subject: compat: convert modes to use portable file type values X-Git-Tag: v2.3.0-rc0~59^2 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/d543d9c0f44a89f30ec1670f16c698b5da801476?ds=inline;hp=d543d9c0f44a89f30ec1670f16c698b5da801476 compat: convert modes to use portable file type values This adds simple wrapper functions around calls to stat(), fstat(), and lstat() that translate the operating system's native file type bits to those used by most operating systems. It also rewrites the S_IF* macros to the common values, so all file type processing is performed using the translated modes. This makes projects portable across operating systems that use different file type definitions. Only the file type bits may be affected by these compatibility functions; the file permission bits are assumed to be 07777 and are passed through unchanged. Signed-off-by: David Michael Signed-off-by: Junio C Hamano ---