fix disfigurement if table size 0 Bytes

This commit is contained in:
Steve Alberty
2001-07-11 16:51:56 +00:00
parent aa076b11c5
commit 4d2d26de5d
2 changed files with 3 additions and 1 deletions

View File

@@ -9,6 +9,7 @@ $Source$
* tbl_properties.php3: fix division by zero error
* tbl_change.php3: enlarge binary protection to (var)char binary
types
* db_details.php3: fix disfigurement if table size 0 Bytes
2001-07-09 Lo<4C>c Chapeaux <lolo@phpheaven.net>
* header.inc.php3: cosmetic changes.

View File

@@ -121,7 +121,8 @@ else if (MYSQL_MAJOR_VERSION >= 3.23 && isset($tbl_cache)) {
$tblsize = $sts_data['Data_length'] + $sts_data['Index_length'];
$sum_size += $tblsize;
$sum_entries += $sts_data['Rows'];
list($formated_size, $unit) = format_byte_down($tblsize, 3, 1);
if ($tblsize>0) list($formated_size, $unit) = format_byte_down($tblsize, 3, 1);
else list($formated_size, $unit) = format_byte_down($tblsize, 3, 0);
?>
<td align="right">
<?php echo number_format($sts_data['Rows'], 0, $number_decimal_separator, $number_thousands_separator) . "\n"; ?>