summaryrefslogtreecommitdiff
path: root/plugins/DbChecker/src/selectdb.cpp
diff options
context:
space:
mode:
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);