VOP_OLD_REMOVE(9)

NAME
VOP_OLD_REMOVE, VOP_OLD_RMDIR - remove a file or directory

SYNOPSIS
#include <sys/param.h>
#include <sys/vnode.h>
int
VOP_OLD_REMOVE(struct vnode *dvp, struct vnode *vp, struct componentname *cnp);
int
VOP_OLD_RMDIR(struct vnode *dvp, struct vnode *vp, struct componentname *cnp);

DESCRIPTION
These entry points remove files and directories respectively.

The arguments are:

dvp the vnode of the directory

vp  the vnode of the file to be removed

cnp pathname information about the file

LOCKS
Both dvp and vp should be locked on entry and remain locked on return.

RETURN VALUES
Zero is returned on success, otherwise an error code is returned.

ERRORS

[EPERM]
    the file is immutable

[ENOTEMPTY]
    attempt to remove a directory which is not empty

SEE ALSO
vnode(9), VOP_OLD_LOOKUP(9)

AUTHORS
This man page was written by Doug Rabson.