summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--modules/system/system.install16
-rw-r--r--update.php15
2 files changed, 17 insertions, 14 deletions
diff --git a/modules/system/system.install b/modules/system/system.install
index 8ffd1d5f0..b0903b0bc 100644
--- a/modules/system/system.install
+++ b/modules/system/system.install
@@ -3861,20 +3861,8 @@ function system_update_6027() {
// Create the blocks.cache column.
db_add_field($ret, 'blocks', 'cache', array('type' => 'int', 'not null' => TRUE, 'default' => 0, 'size' => 'tiny'));
- // Create the cache_block table.
- $schema['cache_block'] = array(
- 'fields' => array(
- 'cid' => array('type' => 'varchar', 'length' => 255, 'not null' => TRUE, 'default' => ''),
- 'data' => array('type' => 'blob', 'not null' => FALSE, 'size' => 'big'),
- 'expire' => array('type' => 'int', 'not null' => TRUE, 'default' => 0),
- 'created' => array('type' => 'int', 'not null' => TRUE, 'default' => 0),
- 'headers' => array('type' => 'text', 'not null' => FALSE),
- 'serialized' => array('type' => 'int', 'size' => 'small', 'not null' => TRUE, 'default' => 0)
- ),
- 'indexes' => array('expire' => array('expire')),
- 'primary key' => array('cid'),
- );
- db_create_table($ret, 'cache_block', $schema['cache_block']);
+ // The cache_block table is created in update_fix_d6_requirements() since
+ // calls to cache_clear_all() would otherwise cause warnings.
// Fill in the values for the new 'cache' column,
// by refreshing the {blocks} table.
diff --git a/update.php b/update.php
index 315175caa..ee67c4d88 100644
--- a/update.php
+++ b/update.php
@@ -771,6 +771,21 @@ function update_fix_d6_requirements() {
db_add_field($ret, 'locales_source', 'version', array('type' => 'varchar', 'length' => 20, 'not null' => TRUE, 'default' => 'none'));
}
variable_set('update_d6_requirements', TRUE);
+
+ // Create the cache_block table. See system_update_6027() for more details.
+ $schema['cache_block'] = array(
+ 'fields' => array(
+ 'cid' => array('type' => 'varchar', 'length' => 255, 'not null' => TRUE, 'default' => ''),
+ 'data' => array('type' => 'blob', 'not null' => FALSE, 'size' => 'big'),
+ 'expire' => array('type' => 'int', 'not null' => TRUE, 'default' => 0),
+ 'created' => array('type' => 'int', 'not null' => TRUE, 'default' => 0),
+ 'headers' => array('type' => 'text', 'not null' => FALSE),
+ 'serialized' => array('type' => 'int', 'size' => 'small', 'not null' => TRUE, 'default' => 0)
+ ),
+ 'indexes' => array('expire' => array('expire')),
+ 'primary key' => array('cid'),
+ );
+ db_create_table($ret, 'cache_block', $schema['cache_block']);
}
return $ret;