libssh2_sftp_close_handle.3 (1386B)
1.TH libssh2_sftp_close_handle 3 "1 Jun 2007" "libssh2 0.15" "libssh2" 2.SH NAME 3libssh2_sftp_close_handle - close filehandle 4.SH SYNOPSIS 5.nf 6#include <libssh2.h> 7#include <libssh2_sftp.h> 8 9int 10libssh2_sftp_close_handle(LIBSSH2_SFTP_HANDLE *handle); 11 12int 13libssh2_sftp_close(LIBSSH2_SFTP_HANDLE *handle); 14 15int 16libssh2_sftp_closedir(LIBSSH2_SFTP_HANDLE *handle); 17.fi 18.SH DESCRIPTION 19\fIhandle\fP - SFTP File Handle as returned by \fBlibssh2_sftp_open_ex(3)\fP 20or \fBlibssh2_sftp_opendir(3)\fP (which is a macro). 21 22Close an active LIBSSH2_SFTP_HANDLE. Because files and directories share the 23same underlying storage mechanism these methods may be used 24interchangeably. \fBlibssh2_sftp_close(3)\fP and \fBlibssh2_sftp_closedir(3)\fP 25are macros for \fBlibssh2_sftp_close_handle(3)\fP. 26.SH RETURN VALUE 27Return 0 on success or negative on failure. It returns 28LIBSSH2_ERROR_EAGAIN when it would otherwise block. While 29LIBSSH2_ERROR_EAGAIN is a negative number, it is not really a failure per se. 30.SH ERRORS 31\fILIBSSH2_ERROR_ALLOC\fP - An internal memory allocation call failed. 32 33\fILIBSSH2_ERROR_SOCKET_SEND\fP - Unable to send data on socket. 34 35\fILIBSSH2_ERROR_SOCKET_TIMEOUT\fP - 36 37\fILIBSSH2_ERROR_SFTP_PROTOCOL\fP - An invalid SFTP protocol response was 38received on the socket, or an SFTP operation caused an errorcode to 39be returned by the server. 40.SH SEE ALSO 41.BR libssh2_sftp_open_ex(3)