Use S_IS* macros instead of S_IF*, which are non-posix

darcs-hash:20060801002411-ac50b-e5afcbfe4adfc54333c982b43309091c1cbcc1c9.gz
This commit is contained in:
axel 2006-08-01 10:24:11 +10:00
parent 8e6dbe245c
commit 03f6656af6
2 changed files with 3 additions and 3 deletions

View File

@ -81,7 +81,7 @@ static int my_env_set( const wchar_t *key, array_list_t *val, int scope )
show_perror = 1;
}
if( !( S_IFDIR & buff.st_mode ) )
if( !( S_ISDIR(buff.st_mode) ) )
{
error = 1;

View File

@ -395,7 +395,7 @@ static int test_flags( wchar_t *filename,
return 0;
}
if( S_IFDIR & buf.st_mode )
if( S_ISDIR( buf.st_mode ) )
return 1;
if( flags & EXECUTABLES_ONLY )
@ -684,7 +684,7 @@ int wildcard_expand( const wchar_t *wc,
if( !stat_res )
{
if( buf.st_mode & S_IFDIR )
if( S_ISDIR(buf.st_mode) )
{
new_len = wcslen( new_dir );
new_dir[new_len] = L'/';