| 総合手引 | セクション 9 | English | オプション |
#include <sys/param.h>
#include <sys/vnode.h>
引数は以下の通りです。
| dvp | |
| ディレクトリの vnode。 | |
| vp | |
| 削除対象ファイルの vnode。 | |
| cnp | |
| ファイルのパス名情報。 | |
int
vop_remove(struct vnode *dvp, struct vnode *vp, struct componentname *cnp)
{
int error = 0;
if (vp is immutable) {
error = EPERM;
goto out;
}
/*
* ディレクトリから cnp->cn_nameptr の名前を削除し、vp のリンク
* カウントを更新します。
*/
...;
/*
* "." の削除を試みる場合は注意してください。XXX これはより
* 上層で取り扱われるべきです。
*/
if (dvp == vp)
vrele(vp);
else
vput(vp);
vput(dvp);
return error;
}
| [EPERM] | |
| ファイルは変更不可能です。 | |
| [ENOTEMPTY] | |
| 空ではないディレクトリを削除しようとしました。 | |
| VOP_REMOVE (9) | July 24, 1996 |
| 総合手引 | セクション 9 | English | オプション |
このマニュアルページサービスについてのご意見は Ben Bullock にお知らせください。 Privacy policy.
| “ | … one of the main causes of the fall of the Roman Empire was that, lacking zero, they had no way to indicate successful termination of their C programs. | ” |
| — Robert Firth | ||