IMFS_fchmod()
rtems_libio_t *iop mode_t mode
imfs_fchmod.c
This routine will obtain the pointer to the IMFS_jnode_t structure from the information currently in the file control block.
Based on configuration the routine will acquire the user ID from a call to getuid() or from the IMFS_jnode_t structure.
It then checks to see if we have the ownership rights to alter the mode of the file. If the caller does not, an error code is returned.
An additional test is performed to verify that the caller is not trying to alter the nature of the node. If the caller is attempting to alter more than the permissions associated with user group and other, an error is returned.
If all the preconditions are met, the user, group and other fields are set based on the mode calling parameter.
Copyright © 1988-2003 OAR Corporation