﻿id,summary,reporter,owner,description,type,status,priority,milestone,component,version,severity,resolution,keywords,cc
15013,[fix] Automatic plugin installer/updater fails to upload files over 64k (ftpext mode),gasparch,,"In case if plugin/theme has a file which is larger than 64k - it fails to copy that file over FTP, sometimes leaving temp files exactly 65536 bytes long. FTP server itself has no problems copying such files (tested manually).

It turns out that reading file in 8k chunks hits some bug in php randomly. So it works rarely, but msot of the time fails.
Smaller buffer size works without any problems. 

So I've changed the 
wp-admin/includes/class-wp-filesystem-ftpext.php , line 107


        while ( ! feof($temp) )
            $contents .= fread($temp, 8192);

to

        while ( ! feof($temp) )
            $contents .= fread($temp, 4096);

and it started to work every time I use automatic updater/installer.

CentOS 2.6.18-194.8.1.el5.028stab070.5 i686 athlon, Apache 2.0, PHP 5.2.14, latest version of WordPress (3.0.1), pureftp.
",defect (bug),closed,normal,,Upgrade/Install,3.0.1,normal,invalid,,ford@…
