RTEMS Logo

RTEMS 4.7.2 On-Line Library


fchmod

PREV UP NEXT Bookshelf RTEMS Filesystem Design Guide

4.9: fchmod

File:

fchmod.c

Processing:

This routine will alter the permissions of a node in a filesystem. It is layered on the following functions and macros:

Development Comments:

The routine will test to see if the file descriptor index is associated with a network connection. If it is, an error is returned from this routine.

The file descriptor index is used to obtain the associated file control block.

The file descriptor value is range checked.

The file control block is examined to determine if it has write permissions to allow us to alter the mode of the file.

A test is made to determine if the handler table that is referenced in the file control block contains an entry for the fchmod() handler function. If it does not, an error is returned to the calling routine.

If the fchmod() handler function exists, it is called with the file control block and the desired mode as parameters.


PREV UP NEXT Bookshelf RTEMS Filesystem Design Guide

Copyright © 1988-2004 OAR Corporation