From 699994b520949edbb5953453af5134283dbf394f Mon Sep 17 00:00:00 2001 From: Michael Dale Date: Thu, 6 Aug 2009 22:25:47 +0000 Subject: [PATCH] * made wgMaxUploadSize check work with js2/firefogg uploading interface. --- includes/upload/UploadFromChunks.php | 8 +++----- .../example_usage/Firefogg_Make_Advanced.html | 2 +- .../jquery/jquery.ui-1.7.1/ui/ui.dialog.js | 20 +++++++++---------- .../libAddMedia/mvBaseUploadInterface.js | 12 ++++++++++- js2/mwEmbed/libClipEdit/mvClipEdit.js | 5 ++++- js2/mwEmbed/libSequencer/mvSequencer.js | 4 ++-- 6 files changed, 31 insertions(+), 20 deletions(-) diff --git a/includes/upload/UploadFromChunks.php b/includes/upload/UploadFromChunks.php index 5121a9507b..ce22b6549b 100644 --- a/includes/upload/UploadFromChunks.php +++ b/includes/upload/UploadFromChunks.php @@ -229,16 +229,14 @@ class UploadFromChunks extends UploadBase { } return $status; } else { - //check to make sure we have not expanded beyond $wgMaxUploadSize - if( ( filesize( $this->mTempAppendPath ) + filesize( $this->mTempPath ) ) > $wgMaxUploadSize ) - $status = Status::newFatal( 'largefileserver' ); - if( is_file( $this->getRealPath( $this->mTempAppendPath ) ) ){ $status = $this->appendToUploadFile( $this->mTempAppendPath, $this->mTempPath ); } else { $status = Status::newFatal( 'filenotfound', $this->mTempAppendPath ); } - + //check to make sure we have not expanded beyond $wgMaxUploadSize + if( filesize( $this->getRealPath( $this->mTempAppendPath ) ) > $wgMaxUploadSize ) + $status = Status::newFatal( 'largefileserver' ); return $status; } diff --git a/js2/mwEmbed/example_usage/Firefogg_Make_Advanced.html b/js2/mwEmbed/example_usage/Firefogg_Make_Advanced.html index 97746f5469..4c91bec4e6 100644 --- a/js2/mwEmbed/example_usage/Firefogg_Make_Advanced.html +++ b/js2/mwEmbed/example_usage/Firefogg_Make_Advanced.html @@ -1,7 +1,7 @@ - Firefogg - Make Ogg Video in your Browser + Firefogg - Make Ogg Video in your Browser