vxfs_nattr_unlink - remove a named data stream
cc -I /opt/VRTS/include -L /opt/VRTS/lib
-l vxfsutil -ldl
cc -I /opt/VRTS/include -L /opt/VRTS/lib/sparcv9
-l vxfsutil -ldl
int vxfs_nattr_unlink(int fd, char *path);
The vxfs_nattr_unlink() function removes the directory entry for the named data stream pointed to by path associated with fd and decrements the link count of the associated named data stream by one.
When the named data stream link count becomes zero and no process has the file open, the space occupied by the file is freed and the data stream is no longer accessible.
To remove the attribute file, write permission is required on the original file.
Upon successful completion, vxfs_nattr_unlink() returns zero. Otherwise, -1 is returned, errno is set to indicate the error, and the file is not unlinked.
Search permission does not exist for a component of the path prefix. There is no write permission on the directory containing the link to be removed. The parent directory has the sticky bit set and the file is not writable by the user. The user does not own the parent directory or the file.
The path argument points to an illegal address.
An interrupt signal was sent during function execution.
The length of the path argument exceeds PATH_MAX. A path name component is longer than NAME_MAX while _POSIX_NO_TRUNC is in effect.
The named file does not exist or is a null path name.
The path argument points to a remote system and the link to that system is not active.
A component of the path prefix is not a directory.
The named file is a directory and the calling process does not have the privileges needed to perform the operation.
The directory entry to be unlinked is part of a read-only file system.
vxfs_nattr_link(3), vxfs_nattr_open(3), vxfs_nattr_rename(3) vxfs_nattr_utimes(3)