summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CHANGELOG.txt2
-rw-r--r--modules/system/system.install16
2 files changed, 18 insertions, 0 deletions
diff --git a/CHANGELOG.txt b/CHANGELOG.txt
index 028760a99..e7817422b 100644
--- a/CHANGELOG.txt
+++ b/CHANGELOG.txt
@@ -1,6 +1,8 @@
Drupal 7.25, xxxx-xx-xx (development version)
-----------------------
+- Changed the database schema of the {file_managed} table to allow Drupal to
+ manage files larger than 4 GB.
- Changed the File module's hook_field_load() implementation to prevent file
entity properties which have the same name as file or image field properties
from overwriting the field properties (minor API change).
diff --git a/modules/system/system.install b/modules/system/system.install
index 7d3c95916..3c83c37e9 100644
--- a/modules/system/system.install
+++ b/modules/system/system.install
@@ -858,6 +858,7 @@ function system_schema() {
'filesize' => array(
'description' => 'The size of the file in bytes.',
'type' => 'int',
+ 'size' => 'big',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0,
@@ -3134,6 +3135,21 @@ function system_update_7078() {
), array('unique keys' => array('formats' => array('format', 'type'))));
}
+/*
+ * Convert the 'filesize' column in {file_managed} to a bigint.
+ */
+function system_update_7079() {
+ $spec = array(
+ 'description' => 'The size of the file in bytes.',
+ 'type' => 'int',
+ 'size' => 'big',
+ 'unsigned' => TRUE,
+ 'not null' => TRUE,
+ 'default' => 0,
+ );
+ db_change_field('file_managed', 'filesize', 'filesize', $spec);
+}
+
/**
* @} End of "defgroup updates-7.x-extra".
* The next series of updates should start at 8000.