summaryrefslogtreecommitdiff
path: root/plugins/DbChecker/src/selectdb.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2014-07-20 11:09:16 +0000
committerGeorge Hazan <george.hazan@gmail.com>2014-07-20 11:09:16 +0000
commite35464b3a1c3a5af68b348803049d90d73c1bc0d (patch)
treebe5f05a3cb1b490653132afb735d9befeba4352b /plugins/DbChecker/src/selectdb.cpp
parent7663d8886a2e059232287b6652ead02142f6d6fc (diff)
all profile conversion stuff moved to dbchecker
git-svn-id: http://svn.miranda-ng.org/main/trunk@9880 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/DbChecker/src/selectdb.cpp')
-rw-r--r--plugins/DbChecker/src/selectdb.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/plugins/DbChecker/src/selectdb.cpp b/plugins/DbChecker/src/selectdb.cpp
index a013835748..c5455ef4fd 100644
--- a/plugins/DbChecker/src/selectdb.cpp
+++ b/plugins/DbChecker/src/selectdb.cpp
@@ -31,6 +31,7 @@ static bool CheckBroken(const TCHAR *ptszFullPath)
int OpenDatabase(HWND hdlg, INT iNextPage)
{
TCHAR tszMsg[1024];
+ int error = 0;
if (opts.dbChecker == NULL) {
DATABASELINK* dblink = FindDatabasePlugin(opts.filename);
@@ -50,7 +51,6 @@ LBL_Error:
goto LBL_Error;
}
- int error = 0;
opts.dbChecker = dblink->CheckDB(opts.filename, &error);
if (opts.dbChecker == NULL) {
if ((opts.error = GetLastError()) == 0)
@@ -61,7 +61,12 @@ LBL_Error:
opts.dblink = dblink;
}
- if (iNextPage == IDD_FILEACCESS)
+ // force check
+ if (error == EGROKPRF_OBSOLETE) {
+ opts.bAggressive = opts.bBackup = true;
+ PostMessage(GetParent(hdlg), WZM_GOTOPAGE, IDD_PROGRESS, (LPARAM)ProgressDlgProc);
+ }
+ else if (iNextPage == IDD_FILEACCESS)
PostMessage(GetParent(hdlg), WZM_GOTOPAGE, IDD_FILEACCESS, (LPARAM)FileAccessDlgProc);
else
PostMessage(GetParent(hdlg), WZM_GOTOPAGE, IDD_PROGRESS, (LPARAM)ProgressDlgProc);