From ee06363594a5bc5b05a9576bbc98c0884e959c2d Mon Sep 17 00:00:00 2001 From: Nicolas Boichat Date: Fri, 16 Jul 2004 21:47:03 +0000 Subject: [PATCH] - wxbRestorePanel : Fixed crash when an error occurs while querying restore list (reported by Dan Langille). git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@1472 91ce42f0-d328-0410-95d8-f526ca767f89 --- bacula/src/wx-console/CHANGELOG | 4 ++++ bacula/src/wx-console/wxbrestorepanel.cpp | 8 ++++++++ 2 files changed, 12 insertions(+) diff --git a/bacula/src/wx-console/CHANGELOG b/bacula/src/wx-console/CHANGELOG index f07925b9ff..ac97a08682 100644 --- a/bacula/src/wx-console/CHANGELOG +++ b/bacula/src/wx-console/CHANGELOG @@ -1,3 +1,7 @@ +16-07-2004 : + - wxbRestorePanel : Fixed crash when an error occurs while querying + restore list (reported by Dan Langille). + 15-07-2004 : - wxbMainFrame : When an unexpected question is in this format (***? (yes/mod/no):), a list is shown to choose one of these diff --git a/bacula/src/wx-console/wxbrestorepanel.cpp b/bacula/src/wx-console/wxbrestorepanel.cpp index d4f2388b5f..1783446fc8 100644 --- a/bacula/src/wx-console/wxbrestorepanel.cpp +++ b/bacula/src/wx-console/wxbrestorepanel.cpp @@ -1123,6 +1123,14 @@ void wxbRestorePanel::CmdListJobs() { delete dt; return; } + else if (((*dt)[i].Index("ERROR") > -1) || ((*dt)[i].Index("Query failed") > -1)) { + configPanel->AddRowChoice("Before", "Cannot get previous backups list, see console."); + configPanel->SetRowSelection("Before", 0); + configPanel->EnableApply(true); // Enabling the not existing apply button disables the ok button. + delete tableparser; + delete dt; + return; + } } } -- 2.39.2