mirror of
https://github.com/phpseclib/phpseclib.git
synced 2024-11-11 16:15:52 +00:00
SSH2: Make $stop be after all network activity
This commit is contained in:
parent
4c3bf94806
commit
bbed0916cd
@ -2036,7 +2036,6 @@ class Net_SSH2 {
|
|||||||
|
|
||||||
$start = strtok(microtime(), ' ') + strtok(''); // http://php.net/microtime#61838
|
$start = strtok(microtime(), ' ') + strtok(''); // http://php.net/microtime#61838
|
||||||
$raw = fread($this->fsock, $this->decrypt_block_size);
|
$raw = fread($this->fsock, $this->decrypt_block_size);
|
||||||
$stop = strtok(microtime(), ' ') + strtok('');
|
|
||||||
|
|
||||||
if (empty($raw)) {
|
if (empty($raw)) {
|
||||||
return '';
|
return '';
|
||||||
@ -2059,6 +2058,7 @@ class Net_SSH2 {
|
|||||||
$buffer.= $temp;
|
$buffer.= $temp;
|
||||||
$remaining_length-= strlen($temp);
|
$remaining_length-= strlen($temp);
|
||||||
}
|
}
|
||||||
|
$stop = strtok(microtime(), ' ') + strtok('');
|
||||||
if (!empty($buffer)) {
|
if (!empty($buffer)) {
|
||||||
$raw.= $this->decrypt !== false ? $this->decrypt->decrypt($buffer) : $buffer;
|
$raw.= $this->decrypt !== false ? $this->decrypt->decrypt($buffer) : $buffer;
|
||||||
$buffer = $temp = '';
|
$buffer = $temp = '';
|
||||||
|
Loading…
Reference in New Issue
Block a user