20 int _access( const char *_path, int _amode )
22 DWORD Attributes = GetFileAttributesA(_path);
24 if ( Attributes == -1 )
27 if ( (_amode & W_OK) == W_OK ) {
28 if ( (Attributes & FILE_ATTRIBUTE_READONLY) == FILE_ATTRIBUTE_READONLY )
31 if ( (_amode & D_OK) == D_OK ) {
32 if ( (Attributes & FILE_ATTRIBUTE_DIRECTORY) != FILE_ATTRIBUTE_DIRECTORY )