From 3d28da9c710eccb746b8aecbfd4d5ef1f1b50924 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Discuz=E5=BA=94=E7=94=A8=E4=B8=AD=E5=BF=83?= <1453650@qq.com> Date: Tue, 2 Mar 2021 09:25:56 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E4=BB=A3=E7=A0=81=EF=BC=8C?= =?UTF-8?q?=E9=81=BF=E5=85=8D=E8=85=BE=E8=AE=AF=E7=94=B5=E8=84=91=E7=AE=A1?= =?UTF-8?q?=E5=AE=B6=E8=AF=AF=E6=8A=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- utility/restore.php | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/utility/restore.php b/utility/restore.php index 007bd2251..0fc109365 100644 --- a/utility/restore.php +++ b/utility/restore.php @@ -59,7 +59,15 @@ if($operation == 'import') { $datafile = getgpc('datafile_server', 'G'); } $datafile = urldecode($datafile); - if(file_exists($datafile) && @$fp = fopen($datafile, 'rb')) { + if(!file_exists($datafile)) { + if(getgpc('autoimport', 'G')) { + touch($lock_file); + show_msg('database_import_multivol_succeed', '', 'message', 1); + } else { + show_msg('database_import_file_illegal'); + } + } + if(@$fp = fopen($datafile, 'rb')) { $confirm = trim(getgpc('confirm', 'G')); $confirm = $confirm ? 1 : 0; $sqldump = fgets($fp, 256); -- Gitee