From f5c18873fa32b2b3ab6a9501c2fd3f0028d2f826 Mon Sep 17 00:00:00 2001 From: lxnay Date: Tue, 13 Jan 2009 10:49:36 +0000 Subject: [PATCH] Entropy/Equo: - when restoring a database backup, check if the choice selected by the users is valid git-svn-id: http://svn.sabayonlinux.org/projects/entropy/trunk@2892 cd1c1023-2f26-0410-ae45-c471fc1f0318 --- client/text_rescue.py | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/client/text_rescue.py b/client/text_rescue.py index 199b26a1d..e4e196d0c 100644 --- a/client/text_rescue.py +++ b/client/text_rescue.py @@ -637,11 +637,14 @@ def database(options): ('db',('combo',(_('Select the database you want to restore'),mydblist),),fake_cb,True) ] - data = Equo.inputBox(red(_("Entropy installed packages database restore tool")), input_params, cancel_button = True) - if data == None: - return 1 - myid, dbx = data['db'] - dbpath = dblist[myid] + while 1: + data = Equo.inputBox(red(_("Entropy installed packages database restore tool")), input_params, cancel_button = True) + if data == None: + return 1 + myid, dbx = data['db'] + dbpath = dblist.get(myid) + if dbpath == None: continue + break status, err_msg = Equo.restoreDatabase(dbpath, etpConst['etpdatabaseclientfilepath']) if status: