Opened 2 years ago
Closed 2 years ago
#57063 closed defect (bug) (duplicate)
WordPress 6.1, WP_Filesystem_FTPext breaks on the default FreeBSD FTPD server
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 6.1 |
Component: | Filesystem API | Keywords: | |
Focuses: | Cc: |
Description
I update my WordPress installations via WP_Filesystem_FTPext .
The FTP server I use is the default FTPD deamon from FreeBSD 13.1.
Since the 6.1 update plugin installing doesn't work anymore. (It doesn't create the plugin directories)
The reason is that the method exists doesn't return the correct value anymore.
It always return true.
Reason is that the raw ls command returns a 'ftpd: /nonexisten/file: No such file or directory'
ftp> ls /nonexisten/file 229 Entering Extended Passive Mode (|||65185|) 150 Opening ASCII mode data connection for '/bin/ls'. ftpd: /nonexisten/file: No such file or directory 226 Transfer complete.
The exist method checks if the empty method if the result is empty.
! empty( ftp_rawlist( $this->link, $path ) );
Which it never will because it contains the message ftpd: /nonexisten/file: No such file or directory
When I copy the 6.0 version of wp-admin/includes/class-wp-filesystem-ftpext.php
it works again.
This issue is related to #56966
Hi @gamecreature, welcome back to Trac and thanks for opening this ticket!
The change to
::exists()
was reverted in [54816] and released with WordPress 6.1.1.Can you test this again and let us know if you still have this issue in WordPress 6.1.1? Thanks!