v7 man page for unlink

Query: unlink

OS: v7

Section: 2

Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar

UNLINK(2)							System Calls Manual							 UNLINK(2)

NAME
unlink - remove directory entry
SYNOPSIS
unlink(name) char *name;
DESCRIPTION
Name points to a null-terminated string. Unlink removes the entry for the file pointed to by name from its directory. If this entry was the last link to the file, the contents of the file are freed and the file is destroyed. If, however, the file was open in any process, the actual destruction is delayed until it is closed, even though the directory entry has disappeared.
SEE ALSO
rm(1), link(2)
DIAGNOSTICS
Zero is normally returned; -1 indicates that the file does not exist, that its directory cannot be written, or that the file contains pure procedure text that is currently in use. Write permission is not required on the file itself. It is also illegal to unlink a directory (except for the super-user).
ASSEMBLER
(unlink = 10.) sys unlink; name UNLINK(2)
Related Man Pages
unlink(2) - mojave
unlink(2) - minix
unlink(2) - ultrix
unlink(1) - osf1
unlink(2) - osx
Similar Topics in the Unix Linux Community
using C to copy a file ...
What does unlink"tmep.log" do?
perl unlink question
Cron could not unlink FIFO
du and df do not match on NFS share