From ac724eb3fb7ab2bf0554a497dd8d63633722ada8 Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Fri, 24 Apr 2009 09:33:47 +0000 Subject: Improve the sftp async read functions. git-svn-id: svn+ssh://svn.berlios.de/svnroot/repos/libssh/trunk@602 7dcaeef0-15fb-0310-b436-a5af3365683c --- include/libssh/sftp.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'include/libssh') diff --git a/include/libssh/sftp.h b/include/libssh/sftp.h index f7266bb3..37b45a90 100644 --- a/include/libssh/sftp.h +++ b/include/libssh/sftp.h @@ -377,7 +377,8 @@ ssize_t sftp_read(SFTP_FILE *file, void *buf, size_t count); * * @param len Size to read in bytes. * - * @return A u32 identifier corresponding to the sent request. + * @return An identifier corresponding to the sent request, < 0 on + * error. * * @warning When calling this function, the internal offset is * updated corresponding to the len parameter. @@ -391,7 +392,7 @@ ssize_t sftp_read(SFTP_FILE *file, void *buf, size_t count); * @see sftp_async_read() * @see sftp_open() */ -u32 sftp_async_read_begin(SFTP_FILE *file, u32 len); +int sftp_async_read_begin(SFTP_FILE *file, u32 len); /** * @brief Wait for an asynchronous read to complete and save the data. @@ -408,9 +409,8 @@ u32 sftp_async_read_begin(SFTP_FILE *file, u32 len); * function. * * @return Number of bytes read, 0 on EOF, SSH_ERROR if an error - * occured, SSH_AGAIN SSH_AGAIN if the file is opened in - * nonblocking mode and the request hasn't been executed - * yet. + * occured, SSH_AGAIN if the file is opened in nonblocking + * mode and the request hasn't been executed yet. * * @warning A call to this function with an invalid identifier * will never return. -- cgit