aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/functions_transfer.php
diff options
context:
space:
mode:
authorAndreas Fischer <bantu@phpbb.com>2009-07-22 01:26:09 +0000
committerAndreas Fischer <bantu@phpbb.com>2009-07-22 01:26:09 +0000
commit81e67fbef141ea47249b5f9d1a4e1cb34263b248 (patch)
tree7c24b3b3471be5a6096c4b1f8f383bd28624a144 /phpBB/includes/functions_transfer.php
parent2bb2e4a43b30bd3a686106865c84786de42d50e8 (diff)
downloadforums-81e67fbef141ea47249b5f9d1a4e1cb34263b248.tar
forums-81e67fbef141ea47249b5f9d1a4e1cb34263b248.tar.gz
forums-81e67fbef141ea47249b5f9d1a4e1cb34263b248.tar.bz2
forums-81e67fbef141ea47249b5f9d1a4e1cb34263b248.tar.xz
forums-81e67fbef141ea47249b5f9d1a4e1cb34263b248.zip
Fix bug #46295 - Be less strict with FTP daemons when getting directory filelists.
Authorised by: bantu ;-) git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@9820 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/functions_transfer.php')
-rw-r--r--phpBB/includes/functions_transfer.php8
1 files changed, 8 insertions, 0 deletions
diff --git a/phpBB/includes/functions_transfer.php b/phpBB/includes/functions_transfer.php
index 2146d5fa0b..c1211eda52 100644
--- a/phpBB/includes/functions_transfer.php
+++ b/phpBB/includes/functions_transfer.php
@@ -462,6 +462,14 @@ class ftp extends transfer
{
$list = @ftp_nlist($this->connection, $dir);
+ // See bug #46295 - Some FTP daemons don't like './'
+ if ($dir === './')
+ {
+ // Let's try some alternatives
+ $list = (empty($list)) ? @ftp_nlist($this->connection, '.') : $list;
+ $list = (empty($list)) ? @ftp_nlist($this->connection, '') : $list;
+ }
+
// Return on error
if ($list === false)
{