Dear libssh2-devel mailing list,
While interleaving some sftp_seek64 with sftp_read to read different
section of a file, all stays fine until I reach EOF. After that, I can
never get anything back from sftp_read after using sftp_seek64 to get
away from EOF. I've tried with the following patch, and at least for me,
things seem to work better.
PS: I sent an E-mail to this list before registering, and this one
after. Hopefully, I am not double-posting.
diff --git a/src/sftp.c b/src/sftp.c
index 32b215a..48da9f2 100644
@@ -1933,6 +1933,9 @@ libssh2_sftp_seek64(LIBSSH2_SFTP_HANDLE *handle,
handle->u.file.data_left = handle->u.file.data_len = 0;
handle->u.file.data = NULL;
+ /* reset EOF to False */
+ handle->u.file.eof = FALSE;
Received on 2012-01-26