|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2005-05-03 11:24 UTC] deadem at mail dot ru
Description:
------------
patch:
diff ssh2_fopen_wrappers.c.orig ssh2_fopen_wrappers.c
976c976,985
< if (bytesread != libssh2_channel_write(remote_file, buffer, bytesread)) {
---
> size_t realwrite = 0;
> size_t stepwrite = 0;
> while ((stepwrite = libssh2_channel_write(remote_file, buffer + realwrite, bytesread - realwrite)) > 0) {
> realwrite += stepwrite;
> if (bytesread <= realwrite) {
> break;
> }
> }
>
> if (bytesread != realwrite) {
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Oct 26 13:00:02 2025 UTC |
no. see in libssh2-0.8/src/channel.c LIBSSH2_API int libssh2_channel_write_ex(LIBSSH2_CHANNEL *channel, int stream_id, const char *buf, size_t buflen) this function only wait for first window frame and send data of it's size, instead of buflen. if (buflen > channel->local.window_size) { buflen = channel->local.window_size; } if (buflen > channel->local.packet_size) { buflen = channel->local.packet_size; }