2011/8/24 m odd <xieepp_at_gmail.com>
> LIBSSH2_API void
> libssh2_sftp_seek64(LIBSSH2_SFTP_HANDLE *handle, libssh2_uint64_t offset)
> {
> - if(handle)
> - handle->u.file.offset = handle->u.file.offset_sent = offset;
> + if(handle) {
> + handle->u.file.offset = handle->u.file.offset_sent = offset;
> + /* discard the request */
> + sftp_packetlist_flush(handle);
> +
> + /* free the left received data */
> + if (handle->u.file.data_left) {
> + LIBSSH2_FREE(handle->sftp->channel->session, handle->u.file.data);
> + handle->u.file.data_left = handle->u.file.data_len = 0;
> + handle->u.file.data = NULL;
> + }
> + }
> }
>
> Just my point about the problem.
>
> _______________________________________________
> libssh2-devel http://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel
>
>
hey!!, this solves the problem! At least my seek64() calls are working back
again!. You should post this patch so it can be included in the git repo.
Nice work!, and thanks!!
Ezequiel
_______________________________________________
libssh2-devel http://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel
Received on 2011-08-24