Ticket #10522: 10522.3.diff
| File 10522.3.diff, 2.1 KB (added by , 17 years ago) |
|---|
-
wp-admin/includes/file.php
609 609 if ( ! defined('FS_CONNECT_TIMEOUT') ) 610 610 define('FS_CONNECT_TIMEOUT', 30); 611 611 if ( ! defined('FS_TIMEOUT') ) 612 define('FS_TIMEOUT', 30 );612 define('FS_TIMEOUT', 300); 613 613 614 614 if ( is_wp_error($wp_filesystem->errors) && $wp_filesystem->errors->get_error_code() ) 615 615 return false; -
wp-admin/includes/class-wp-filesystem-ftpsockets.php
28 28 return false; 29 29 $this->ftp = new ftp(); 30 30 31 //FTP uses the timeout on a per-connection basis, Others use it on a per-action basis. 32 if ( ! defined('FS_TIMEOUT') ) 33 define('FS_TIMEOUT', 300); 34 31 35 //Set defaults: 32 36 if ( empty($opt['port']) ) 33 37 $this->options['port'] = 21; -
wp-admin/includes/class-wp-filesystem-ftpext.php
29 29 return false; 30 30 } 31 31 32 // Set defaults: 33 //This Class uses the timeout on a per-connection basis, Others use it on a per-action basis. 34 32 //FTP uses the timeout on a per-connection basis, Others use it on a per-action basis. 35 33 if ( ! defined('FS_TIMEOUT') ) 36 define('FS_TIMEOUT', 240);34 define('FS_TIMEOUT', 300); 37 35 36 // Set defaults: 38 37 if ( empty($opt['port']) ) 39 38 $this->options['port'] = 21; 40 39 else … … 82 81 83 82 //Set the Connection to use Passive FTP 84 83 @ftp_pasv( $this->link, true ); 85 if ( @ftp_get_option($this->link, FTP_TIMEOUT_SEC) < F TP_TIMEOUT )86 @ftp_set_option($this->link, FTP_TIMEOUT_SEC, F TP_TIMEOUT);84 if ( @ftp_get_option($this->link, FTP_TIMEOUT_SEC) < FS_TIMEOUT ) 85 @ftp_set_option($this->link, FTP_TIMEOUT_SEC, FS_TIMEOUT); 87 86 88 87 return true; 89 88 }