From e882fe691ba61ea86709de7e16e78a144a0dc24a Mon Sep 17 00:00:00 2001 From: Christian Stimming Date: Tue, 13 Aug 2002 21:31:49 +0000 Subject: [PATCH] fix bug. git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@7171 57a11ea4-9604-0410-9ed3-97b8803252fd --- src/import-export/hbci/hbci-interaction.c | 1 + src/import-export/hbci/hbci-progressmon.c | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/import-export/hbci/hbci-interaction.c b/src/import-export/hbci/hbci-interaction.c index 25fed45603..5450d6bd4d 100644 --- a/src/import-export/hbci/hbci-interaction.c +++ b/src/import-export/hbci/hbci-interaction.c @@ -43,6 +43,7 @@ void gnc_hbci_api_interactors (HBCI_API *api, GtkWidget *parent) data = g_new0 (Inter_data, 1); data->parent = parent; + data->keepAlive = TRUE; // set HBCI_Interactor HBCI_Hbci_setInteractor(HBCI_API_Hbci(api), diff --git a/src/import-export/hbci/hbci-progressmon.c b/src/import-export/hbci/hbci-progressmon.c index 8a3d444b45..06d997a664 100644 --- a/src/import-export/hbci/hbci-progressmon.c +++ b/src/import-export/hbci/hbci-progressmon.c @@ -218,8 +218,10 @@ static void actFinished (void *user_data) data->current_act++; gtk_entry_set_text (GTK_ENTRY (data->action_entry), _("Done")); gtk_progress_set_percentage (GTK_PROGRESS (data->action_progress), - (float) data->current_act / - (float) data->actions); + (data->current_act < data->actions) ? + ((float) data->current_act / + (float) data->actions) : + 1.0); /* Let the widgets be redrawn */ while (g_main_iteration (FALSE)); }