tail head cat sleep
QR code linking to this page

Manual Pages  — VOP_REMOVE

NAME

VOP_REMOVE, VOP_RMDIR – remove a file or directory

CONTENTS

SYNOPSIS

#include <sys/param.h>
#include <sys/vnode.h>

int
VOP_REMOVE(struct vnode *dvp, struct vnode *vp, struct componentname *cnp);

int
VOP_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]
  An attempt was made to remove a directory which is not empty.

SEE ALSO

vnode(9), VOP_LOOKUP(9)

AUTHORS

This manual page was written by Doug Rabson.

VOP_REMOVE (9) July 24, 1996

tail head cat sleep
QR code linking to this page


Please direct any comments about this manual page service to Ben Bullock. Privacy policy.

As soon as we started programming, we found to our surprise that it wasn't as easy to get programs right as we had thought. Debugging had to be discovered. I can remember the exact instant when I realized that a large part of my life from then on was going to be spent in finding mistakes in my own programs.
— Maurice Wilkes