Re: [PATCH v2] compat: convert modes to use portable file type values

2014-12-04 Thread Junio C Hamano
David Michael writes: > On Wed, Dec 3, 2014 at 9:24 PM, David Michael wrote: >> --- /dev/null >> +++ b/compat/stat.c >> @@ -0,0 +1,49 @@ >> +#define _POSIX_C_SOURCE 200112L >> +#include /* NULL */ >> +#include /* *stat, S_IS* */ >> +#include /* mode_t */ > > Oops, the line

Re: [PATCH v2] compat: convert modes to use portable file type values

2014-12-04 Thread David Michael
On Wed, Dec 3, 2014 at 9:24 PM, David Michael wrote: > --- /dev/null > +++ b/compat/stat.c > @@ -0,0 +1,49 @@ > +#define _POSIX_C_SOURCE 200112L > +#include /* NULL */ > +#include /* *stat, S_IS* */ > +#include /* mode_t */ Oops, the line can be removed now that this is no l

[PATCH v2] compat: convert modes to use portable file type values

2014-12-03 Thread David Michael
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