mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-25 11:28:55 +00:00
git-svn-id: file:///svn/phpbb/trunk@7279 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
7c2832fb42
commit
3eec9b84d1
1 changed files with 6 additions and 2 deletions
|
@ -209,10 +209,14 @@ class acp_database
|
||||||
$delete = request_var('delete', '');
|
$delete = request_var('delete', '');
|
||||||
$file = request_var('file', '');
|
$file = request_var('file', '');
|
||||||
|
|
||||||
preg_match('#^backup_\d{10,}_[a-z\d]{16}\.(sql(?:\.(?:gz|bz2))?)$#', $file, $matches);
|
if (!preg_match('#^backup_\d{10,}_[a-z\d]{16}\.(sql(?:\.(?:gz|bz2))?)$#', $file, $matches))
|
||||||
|
{
|
||||||
|
trigger_error($user->lang['BACKUP_INVALID'] . adm_back_link($this->u_action), E_USER_WARNING);
|
||||||
|
}
|
||||||
|
|
||||||
$file_name = $phpbb_root_path . 'store/' . $matches[0];
|
$file_name = $phpbb_root_path . 'store/' . $matches[0];
|
||||||
|
|
||||||
if (!(file_exists($file_name) && is_readable($file_name)))
|
if (!file_exists($file_name) || !is_readable($file_name)))
|
||||||
{
|
{
|
||||||
trigger_error($user->lang['BACKUP_INVALID'] . adm_back_link($this->u_action), E_USER_WARNING);
|
trigger_error($user->lang['BACKUP_INVALID'] . adm_back_link($this->u_action), E_USER_WARNING);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue