SSH2: set stream timeout before calling stream_get_contents

This commit is contained in:
terrafrost 2024-02-06 04:29:25 -06:00
parent 498e67a0c8
commit 2fb6f317d6

View File

@ -3646,6 +3646,9 @@ class SSH2
}
$start = microtime(true);
$sec = (int) floor($this->curTimeout);
$usec = (int) (1000000 * ($this->curTimeout - $sec));
stream_set_timeout($this->fsock, $sec, $usec);
$raw = stream_get_contents($this->fsock, $this->decrypt_block_size);
if (!strlen($raw)) {