From 74ce18013f8e3dad518be895bb427bc75bbde1e2 Mon Sep 17 00:00:00 2001 From: riderkick Date: Tue, 29 Dec 2015 22:31:34 +0800 Subject: [PATCH] tfbdataprocess, close db on createdatabase --- baseunits/uData.pas | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/baseunits/uData.pas b/baseunits/uData.pas index a73ba957f..8d52340b8 100644 --- a/baseunits/uData.pas +++ b/baseunits/uData.pas @@ -1177,10 +1177,9 @@ procedure TDBDataProcess.CreateDatabase(AWebsite: String); var filepath: String; begin - if AWebsite <> '' then - FWebsite := AWebsite; - if FWebsite = '' then - Exit; + if AWebsite <> '' then FWebsite := AWebsite; + if FWebsite = '' then Exit; + Close; filepath := fmdDirectory + DATA_FOLDER + FWebsite + DBDATA_EXT; if FileExistsUTF8(filepath) then DeleteFileUTF8(filepath);