HTTP API: Introduce wp_is_writable() to wrap win_is_writable() and is_writable() to work around PHP Windows ACL issues. See #22900 for trunk

git-svn-id: https://develop.svn.wordpress.org/trunk@23255 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Dion Hulse
2013-01-03 08:04:11 +00:00
parent b558464d2d
commit 80bc158edd
2 changed files with 24 additions and 7 deletions

View File

@@ -141,7 +141,7 @@ class WP_Http {
// Force some settings if we are streaming to a file and check for existence and perms of destination directory
if ( $r['stream'] ) {
$r['blocking'] = true;
if ( ! is_writable( dirname( $r['filename'] ) ) )
if ( ! wp_is_writable( dirname( $r['filename'] ) ) )
return new WP_Error( 'http_request_failed', __( 'Destination directory for file streaming does not exist or is not writable.' ) );
}