From da54eb613b0e68be47211fcd944e5c5a92a05f4e Mon Sep 17 00:00:00 2001 From: terrafrost Date: Thu, 16 Jan 2025 07:31:17 -0600 Subject: [PATCH] SFTP: convert filenames to strings --- phpseclib/Net/SFTP.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/phpseclib/Net/SFTP.php b/phpseclib/Net/SFTP.php index 610a6559f..5d8a4753b 100644 --- a/phpseclib/Net/SFTP.php +++ b/phpseclib/Net/SFTP.php @@ -970,6 +970,8 @@ function realpath($path) */ function _realpath($path) { + $path = (string) $path; + if (!$this->canonicalize_paths) { if ($this->pwd === true) { return '.';