source: trunk/minix/man/man2/symlink.2@ 22

Last change on this file since 22 was 9, checked in by Mattia Monga, 14 years ago

Minix 3.1.2a

File size: 1.8 KB
Line 
1.TH SYMLINK 2 "March 17, 2006"
2.UC 4
3.SH NAME
4symlink \- make a symbolic link to a file
5.SH SYNOPSIS
6.nf
7.ft B
8#include <unistd.h>
9
10int symlink(const char *\fIname1\fP, const char *\fIname2\fP)
11.fi
12.ft R
13.SH DESCRIPTION
14A symbolic link
15.I name2
16is created.
17The link has the name
18.IR name1 .
19.SH "RETURN VALUE
20Upon successful completion, a value of 0 is returned. Otherwise,
21a value of \-1 is returned and
22.B errno
23is set to indicate the error.
24.SH "ERRORS
25.B Symlink
26will fail and no link will be created if one or more of the following
27are true:
28.TP 15
29[ENOTDIR]
30A component of either path prefix is not a directory.
31.TP 15
32[ENAMETOOLONG]
33A path name exceeds PATH_MAX characters.
34.TP 15
35[ENOENT]
36A component of either path prefix does not exist.
37.TP 15
38[EACCES]
39A component of either path prefix denies search permission.
40.TP 15
41[EACCES]
42The requested link requires writing in a directory with a mode
43that denies write permission.
44.TP 15
45[ELOOP]
46Too many symbolic links were encountered in translating one of the pathnames.
47.TP 15
48[EEXIST]
49The link named by \fIname2\fP exists.
50.TP 15
51[ENOSPC]
52The directory in which the entry for the new link is being placed
53cannot be extended because there is no space left on the file
54system containing the directory.
55.ig
56.TP 15
57[EDQUOT]
58The directory in which the entry for the new link
59is being placed cannot be extended because the
60user's quota of disk blocks on the file system
61containing the directory has been exhausted.
62..
63.TP 15
64[EIO]
65An I/O error occurred while reading from or writing to
66the file system to make the directory entry.
67.TP 15
68[EROFS]
69The requested link requires writing in a directory on a read-only file
70system.
71.TP 15
72[EFAULT]
73One of the pathnames specified
74is outside the process's allocated address space.
75.SH "SEE ALSO"
76.BR link (2),
77.BR unlink (2).
Note: See TracBrowser for help on using the repository browser.