Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 9756533

Browse files
committed
Merge branch '3.0'
2 parents 7e00e04 + 0510017 commit 9756533

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

phpseclib/Net/SFTP.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -727,6 +727,9 @@ public function chdir(string $dir): bool
727727
}
728728

729729
$dir = $this->realpath($dir);
730+
if ($dir === false) {
731+
return false;
732+
}
730733

731734
// confirm that $dir is, in fact, a valid directory
732735
if ($this->use_stat_cache && is_array($this->query_stat_cache($dir))) {

0 commit comments

Comments
 (0)