SSH2: fix PHP7.4 errors about accessing bool as string

This commit is contained in:
terrafrost 2021-05-18 22:00:59 -05:00
parent 8204273978
commit 915d1d8ca9
1 changed files with 4 additions and 0 deletions

View File

@ -3548,6 +3548,10 @@ class Net_SSH2
// only called when we've already logged in
if (($this->bitmap & NET_SSH2_MASK_CONNECTED) && $this->isAuthenticated()) {
if (is_bool($payload)) {
return $payload;
}
switch (ord($payload[0])) {
case NET_SSH2_MSG_CHANNEL_REQUEST:
if (strlen($payload) == 31) {