php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #59106 ssh2_scp_send's bug
Submitted: 2010-03-10 09:14 UTC Modified: 2012-06-14 21:19 UTC
From: michael-139 at hotmail dot com Assigned:
Status: Duplicate Package: ssh2 (PECL)
PHP Version: 5.3.0 OS: linux
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: michael-139 at hotmail dot com
New email:
PHP Version: OS:

 

 [2010-03-10 09:14 UTC] michael-139 at hotmail dot com
Description:
------------
i just got the same problem.
and i modify the function ssh2_scp_send.
i make it resume sending when it breaks,

it works.cause the socket is block.

anyone who need it.send me a email.

Reproduce code:
---------------
if ( bytesread !=  libssh2_channel_write(remote_file, buffer , bytesread) ) ) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Failed copying file");
php_stream_close(local_file);
libssh2_channel_free(remote_file);
RETURN_FALSE;
}


Expected result:
----------------
bytesread ==  libssh2_channel_write(remote_file, buffer , bytesread)

Actual result:
--------------

bytesread <libssh2_channel_write(remote_file, buffer , bytesread)

it breaks and report a warning where send a large file.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2012-06-14 21:19 UTC] langemeijer@php.net
This is a duplicate of bug #56425.

Solution is similar to the patch committed in SVN
 [2012-06-14 21:19 UTC] langemeijer@php.net
-Status: Open +Status: Duplicate
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Mar 28 21:01:27 2024 UTC