


      AAAACCCCCCCCEEEESSSSSSSS((((2222))))                   ((((UUUUNNNNIIIIXXXX 5555....0000))))                  AAAACCCCCCCCEEEESSSSSSSS((((2222))))



      NNNNAAAAMMMMEEEE
           access - determine accessibility of a file

      SSSSYYYYNNNNTTTTAAAAXXXX
           iiiinnnntttt aaaacccccccceeeessssssss ((((ppppaaaatttthhhh,,,, aaaammmmooooddddeeee))))
           cccchhhhaaaarrrr ****ppppaaaatttthhhh;;;;
           iiiinnnntttt aaaammmmooooddddeeee;;;;

      DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
           _P_a_t_h points to a path name naming a file.  _A_c_c_e_s_s checks the
           named file for accessibility according to the bit pattern
           contained in _a_m_o_d_e, using the real user ID in place of the
           effective user ID and the real group ID in place of the
           effective group ID.  The bit pattern contained in _a_m_o_d_e is
           constructed as follows:

                04   read
                02   write
                01   execute (search)
                00   check existence of file

           Access to the file is denied if one or more of the following
           are true:

                A component of the path prefix is not a directory.
                [ENOTDIR]

                Read, write, or execute (search) permission is
                requested for a null path name.  [ENOENT]

                The named file does not exist.  [ENOENT]

                Search permission is denied on a component of the path
                prefix.  [EACCES]

                Write access is requested for a file on a read-only
                file system.  [EROFS]

                Write access is requested for a pure procedure (shared
                text) file that is being executed.  [ETXTBSY]

                Permission bits of the file mode do not permit the
                requested access.  [EACCES]

                _P_a_t_h points outside the process's allocated address
                space.  [EFAULT]

           The owner of a file has permission checked with respect to
           the ``owner'' read, write, and execute mode bits, members of
           the file's group other than the owner have permissions
           checked with respect to the ``group'' mode bits, and all
           others have permissions checked with respect to the



      Page 1                                                   (9010-E)






      AAAACCCCCCCCEEEESSSSSSSS((((2222))))                   ((((UUUUNNNNIIIIXXXX 5555....0000))))                  AAAACCCCCCCCEEEESSSSSSSS((((2222))))



           ``other'' mode bits.

      RRRREEEETTTTUUUURRRRNNNN VVVVAAAALLLLUUUUEEEE
           If the requested access is permitted, a value of 0 is
           returned.  Otherwise, a value of -1 is returned and _e_r_r_n_o is
           set to indicate the error.

      SSSSEEEEEEEE AAAALLLLSSSSOOOO
           chmod(2), stat(2).














































      Page 2                                                   (9010-E)



