mirror of
https://github.com/Cacti/cacti.git
synced 2026-12-06 15:14:45 +09:00
Tables outside of pre-built mediumint list cause column errors (#4294)
Closes #4294
This commit is contained in:
1 parent
dcafe08776
commit
f2bdbeed2d
2 files changed
+4
No files matched your search
@@ -14,6 +14,7 @@ Cacti CHANGELOG
|
||||
-issue#4271: Continued timeout of registered processes
|
||||
-issue#4272: dns_get_record(): A temporary server error occurred
|
||||
-issue#4284: Database upgrade can fail - Uncaught argument count error
|
||||
-issue#4294: Tables outside of pre-built list that need fixing, cause bad unknown column errors
|
||||
-issue#4295: If a page contains multiple tables, a larger table can cause smaller ones to lose columns.
|
||||
-feature#4258: Update phpseclib to version 2.0.31
|
||||
|
||||
|
||||
@@ -174,6 +174,9 @@ function database_fix_mediumint_columns() {
|
||||
$columns = array();
|
||||
|
||||
if (!array_key_exists($table, $tables)) {
|
||||
$i = 0;
|
||||
$sql = 'ALTER TABLE ' . $table;
|
||||
|
||||
$columns = array_rekey(
|
||||
db_fetch_assoc("SHOW COLUMNS FROM " . $table),
|
||||
'Field', array('Type', 'Null', 'Key', 'Default', 'Extra')
|
||||
|
||||
Reference in new issue
Block a user