Compatibility with central columns of version 4.4

Signed-off-by: Madhura Jayaratne <madhura.cj@gmail.com>
This commit is contained in:
Madhura Jayaratne 2015-03-06 15:52:44 +05:30
parent 31410ecb0a
commit 390a36eeea
3 changed files with 17 additions and 0 deletions

View File

@ -7,6 +7,7 @@ phpMyAdmin - ChangeLog
- bug Undefined index savedsearcheswork
- bug #4788 Inline edit of DATE fields with NULL, NULL checkbox is under datepicker
- bug #4790 DROP TABLE/VIEW IF EXISTS are not tracked
- bug Compatibility with central columns of version 4.4
4.3.11.1 (2015-03-04)
- bug [security] Risk of BREACH attack, see PMASA-2015-1

View File

@ -113,6 +113,14 @@ $result = PMA_getColumnsList($db, $pos, $max_rows);
$odd_row = false;
$row_num=0;
foreach ($result as $row) {
$vals = explode(',', $row['col_extra']);
if (in_array('auto_increment', $vals)) {
$row['col_extra'] = 'auto_increment';
} elseif (in_array('on update CURRENT_TIMESTAMP', $vals)) {
$row['col_extra'] = 'on update CURRENT_TIMESTAMP';
} else {
$row['col_extra'] = '';
}
$tableHtmlRow = PMA_getHTMLforCentralColumnsTableRow(
$row, $odd_row, $row_num, $db
);

View File

@ -408,6 +408,14 @@ function PMA_makeConsistentWithList($db, $selected_tables)
if ($column['col_length']) {
$query .= '(' . $column['col_length'] . ')';
}
$vals = explode(',', $column['col_extra']);
if (in_array('auto_increment', $vals)) {
$column['col_extra'] = 'auto_increment';
} elseif (in_array('on update CURRENT_TIMESTAMP', $vals)) {
$column['col_extra'] = 'on update CURRENT_TIMESTAMP';
} else {
$column['col_extra'] = '';
}
if ($column['col_isNull']) {
$query .= ' NULL';
} else {