Add constants for ftp connections timeouts, props dd32, see #10522

git-svn-id: https://develop.svn.wordpress.org/trunk@11823 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Ozz
2009-08-15 12:01:04 +00:00
parent 5e8dbc10cd
commit 10cd9df0ae
4 changed files with 19 additions and 14 deletions
+6
View File
@@ -605,6 +605,12 @@ function WP_Filesystem( $args = false, $context = false ) {
$wp_filesystem = new $method($args);
//Define the timeouts for the connections. Only available after the construct is called to allow for per-transport overriding of the default.
if ( ! defined('FS_CONNECT_TIMEOUT') )
define('FS_CONNECT_TIMEOUT', 30);
if ( ! defined('FS_TIMEOUT') )
define('FS_TIMEOUT', 30);
if ( is_wp_error($wp_filesystem->errors) && $wp_filesystem->errors->get_error_code() )
return false;