Properly escape key name when generating config file.

This commit is contained in:
Michal Čihař
2010-08-19 09:55:25 +02:00
parent a7c004d8d4
commit 30c83acddb

View File

@@ -518,6 +518,7 @@ function get_cfg_val($name, $val) {
}
}
if ($type == 'string') {
$k = preg_replace('/[^A-Za-z0-9_]/', '_', $k);
$ret .= get_cfg_val($name . "['$k']", $v);
} elseif ($type == 'int') {
$ret .= ' ' . PMA_var_export($v) . ',' . $crlf;