aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/functions_admin.php
diff options
context:
space:
mode:
authorDavid M <davidmj@users.sourceforge.net>2006-01-14 04:52:41 +0000
committerDavid M <davidmj@users.sourceforge.net>2006-01-14 04:52:41 +0000
commit5ae050ccd21e5b942768172658f68f4b50a50b43 (patch)
tree5f38e4858e73cde14fc1fa1bb0f8a06fdecce8b4 /phpBB/includes/functions_admin.php
parent538f06f84941a7a0cc804e96fe5c46e149133ba5 (diff)
downloadforums-5ae050ccd21e5b942768172658f68f4b50a50b43.tar
forums-5ae050ccd21e5b942768172658f68f4b50a50b43.tar.gz
forums-5ae050ccd21e5b942768172658f68f4b50a50b43.tar.bz2
forums-5ae050ccd21e5b942768172658f68f4b50a50b43.tar.xz
forums-5ae050ccd21e5b942768172658f68f4b50a50b43.zip
- InnoDB would not calculate the total size of a table.. this is now fixed..
- Applied regex majic to the stuff that checks MySQL version. Faster regex and easier to manage. git-svn-id: file:///svn/phpbb/trunk@5450 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/functions_admin.php')
-rw-r--r--phpBB/includes/functions_admin.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/phpBB/includes/functions_admin.php b/phpBB/includes/functions_admin.php
index 08f90fab83..4d2090d5b8 100644
--- a/phpBB/includes/functions_admin.php
+++ b/phpBB/includes/functions_admin.php
@@ -2435,9 +2435,9 @@ function get_database_size()
{
$version = $row['mysql_version'];
- if (preg_match('#^(3\.23|4\.|5\.)#', $version))
+ if (preg_match('#(3\.23|[45]\.)#', $version))
{
- $db_name = (preg_match('#^(3\.23\.[6-9])|(3\.23\.[1-9][1-9])|(4\.)|(5\.)#', $version)) ? "`{$db->dbname}`" : $db->dbname;
+ $db_name = (preg_match('#^(?:3\.23\.(?:[6-9]|[1-9]{2}))|[45]\.#', $version)) ? "`{$db->dbname}`" : $db->dbname;
$sql = "SHOW TABLE STATUS
FROM " . $db_name;
@@ -2446,7 +2446,7 @@ function get_database_size()
$dbsize = 0;
while ($row = $db->sql_fetchrow($result))
{
- if ((isset($row['Type']) && $row['Type'] != 'MRG_MyISAM') || (isset($row['Engine']) && $row['Engine'] == 'MyISAM'))
+ if ((isset($row['Type']) && $row['Type'] != 'MRG_MyISAM') || (isset($row['Engine']) && ($row['Engine'] == 'MyISAM' || $row['Engine'] == 'InnoDB')))
{
if ($table_prefix != '')
{