Do not block XML-RPC uploads when upload_space_check_disabled is true, regardless of fileupload_maxk value. props SergeyBiryukov. fixes #16217

git-svn-id: https://develop.svn.wordpress.org/trunk@21237 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Mark Jaquith 2012-07-09 03:49:23 +00:00
parent fb97d0a0d9
commit 0290c34cee
1 changed files with 1 additions and 1 deletions

View File

@ -1653,7 +1653,7 @@ function redirect_this_site( $deprecated = '' ) {
* @return mixed If the upload is under the size limit, $upload is returned. Otherwise returns an error message.
*/
function upload_is_file_too_big( $upload ) {
if ( is_array( $upload ) == false || defined( 'WP_IMPORTING' ) )
if ( is_array( $upload ) == false || defined( 'WP_IMPORTING' ) || get_site_option( 'upload_space_check_disabled' ) )
return $upload;
if ( strlen( $upload['bits'] ) > ( 1024 * get_site_option( 'fileupload_maxk', 1500 ) ) )