diff --git a/server_engines.php b/server_engines.php index 79625c0c6..e281cee26 100644 --- a/server_engines.php +++ b/server_engines.php @@ -84,16 +84,19 @@ if (empty($engine) || empty($mysql_storage_engines[$engine])) { . ' ' . htmlspecialchars($mysql_storage_engines[$engine]['Comment']) . "\n" . ' ' . "\n" . '
' . "\n"; + $engine_supported = FALSE; switch ($mysql_storage_engines[$engine]['Support']) { case 'DEFAULT': echo '' . ' ' . sprintf($strDefaultEngine, htmlspecialchars($mysql_storage_engines[$engine]['Engine'])) . "\n" . '
' . "\n"; + $engine_supported = TRUE; break; case 'YES': echo '' . "\n" . ' ' . sprintf($strEngineAvailable, htmlspecialchars($mysql_storage_engines[$engine]['Engine'])) . "\n" . '
' . "\n"; + $engine_supported = TRUE; break; case 'NO': echo '' . "\n" @@ -107,25 +110,30 @@ if (empty($engine) || empty($mysql_storage_engines[$engine])) { break; } - switch ($engine) { + if ($engine_supported) switch ($engine) { case 'innodb': case 'innobase': - echo '
' . "\n" - . htmlspecialchars($row[0]) . "\n" - . '' . "\n"; - PMA_DBI_free_result($res); - break; + if ($res = PMA_DBI_try_query('SHOW INNODB STATUS;')) { // We might not have the privileges to do that... + echo '
' . "\n" + . htmlspecialchars($row[0]) . "\n" + . '' . "\n"; + PMA_DBI_free_result($res); + unset($row); + break; + } + unset($res); +// break; default: echo '
' . "\n" . ' ' . $strNoDetailsForEngine . "\n" . '
' . "\n"; break; } + unset($engine_supported); }