1 .\" $Id: libssh2_sftp_symlink_ex.3,v 1.1 2007/06/14 16:33:38 jehousley Exp $
3 .TH libssh2_sftp_symlink_ex 3 "1 Jun 2007" "libssh2 0.15" "libssh2 manual"
5 libssh2_sftp_symlink_ex - read or set a symbolic link
8 #include <libssh2_sftp.h>
11 libssh2_sftp_symlink_ex(LIBSSH2_SFTP *sftp, const char *path, unsigned int path_len, char *target, unsigned int target_len, int link_type);
14 libssh2_sftp_symlink(LIBSSH2_SFTP *sftp, const char *path, char *target);
17 libssh2_sftp_readlink(LIBSSH2_SFTP *sftp, const char *path, char *target, unsigned int target_len);
20 libssh2_sftp_realpath(LIBSSH2_SFTP *sftp, const char *path, char *target, unsigned int target_len);
23 \fIsftp\fP - SFTP instance as returned by
24 .BR libssh2_sftp_init(3)
26 \fIpath\fP - Remote filesystem object to create a symlink from or resolve.
28 \fIpath_len\fP - Length of the name of the remote filesystem object to
29 create a symlink from or resolve.
33 \fBLIBSSH2_SFTP_SYMLINK\fP: Remote filesystem object to link to.
35 \fBLIBSSH2_SFTP_READLINK\fP: Pre-allocated buffer to resolve symlink target into.
37 \fBLIBSSH2_SFTP_REALPATH\fP: Pre-allocated buffer to resolve realpath target into.
39 \fItarget_len\fP - Length of the name of the remote filesystem target object.
41 \fIlink_type\fP - One of the three previously mentioned constants which
42 determines the resulting behavior of this function.
44 .BR libssh2_sftp_symlink(3)
45 : Create a symbolic link between two filesystem objects.
47 .BR libssh2_sftp_readlink(3)
48 : Resolve a symbolic link filesystem object to its next target.
50 .BR libssh2_sftp_realpath(3)
51 : Resolve a complex, relative, or symlinked filepath to its effective target.
54 Return 0 on success or negative on failure. It returns
55 LIBSSH2_ERROR_EAGAIN when it would otherwise block. While
56 LIBSSH2_ERROR_EAGAIN is a negative number, it isn't really a failure per se.
59 \fILIBSSH2_ERROR_ALLOC\fP - An internal memory allocation call failed.
61 \fILIBSSH2_ERROR_SOCKET_SEND\fP - Unable to send data on socket.
63 \fILIBSSH2_ERROR_SOCKET_TIMEOUT\fP -
65 \fILIBSSH2_ERROR_SFTP_PROTOCOL\fP - An invalid SFTP protocol response was
66 received on the socket, or an SFTP operation caused an errorcode to
67 be returned by the server.
70 .BR libssh2_sftp_init(3)