WordPress.org

Ready to get started?Download WordPress

Forums

Patch to fix filesystem/ftpext class on FreeBSD ftp daemon (4 posts)

  1. fwaggle
    Member
    Posted 4 years ago #

    I posted this here, but it struck me that it might not be the right place to get it implemented in WP core, so I'm posting it here too.

    exists() in the filesystem/ftpext class seems broken for me, and the following patch fixes it for me - but I don't know enough PHP to know whether it's suitable for everyone.

    I would truly appreciate if this patch could make it into the next release, because the moment I'm manually patching it into a bunch WordPress installations so that users can update plugins without it deleting the files and giving up.

    --- wp-admin/includes/class-wp-filesystem-ftpext.php 2009-08-04 20:55:35.000000000 +0000
    +++ wp-admin/includes/class-wp-filesystem-ftpext.php 2009-08-04 21:11:16.000000000 +0000
    @@ -201,7 +201,7 @@
            }
    
            function exists($file) {
    -               $list = @ftp_rawlist($this->link, $file, false);
    +               $list = @ftp_nlist($this->link, $file);
                    return !empty($list); //empty list = no file, so invert.
            }
            function is_file($file) {

    Full "technical" babble can be found here: http://wordpress.org/support/topic/291289

  2. fwaggle
    Member
    Posted 4 years ago #

    Has anyone looked at this? This is seriously becoming a huge thorn in my side, every minor update breaks plugin upgrading again and the patch looks so trivial. If someone could at least explain why it's a dumb idea, that'd be great.

  3. Samuel Wood (Otto)
    Tech Ninja
    Posted 4 years ago #

    Sorry we never noticed this, but core patches and such should be posted over on http://core.trac.wordpress.org in order for them to get any attention.

    Your normal wordpress.org login name will work. If you can't find an open ticket describing this issue in a search there, create a new one.

  4. fwaggle
    Member
    Posted 4 years ago #

    Ahh thanks, and in fact it looks like someone else already posted it, others arrived at the same conclusion I did and it's had some testing. Looks as though it'll make it to 2.9. Thanks for pointing me in the right direction I was starting to worry. :)

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.