mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
2002-11-29 Christian Stimming <stimming@tuhh.de>
* src/import-export/hbci/gnc-hbci-utils.c, gnc-hbci-*.c: Catch the condition gracefully when OpenHBCI config file does not exist. git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@7569 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
6488f2a402
commit
a564daf71c
@ -1,3 +1,8 @@
|
|||||||
|
2002-11-29 Christian Stimming <stimming@tuhh.de>
|
||||||
|
|
||||||
|
* src/import-export/hbci/gnc-hbci-utils.c, gnc-hbci-*.c: Catch the
|
||||||
|
condition gracefully when OpenHBCI config file does not exist.
|
||||||
|
|
||||||
2002-11-29 Derek Atkins <derek@ihtfp.com>
|
2002-11-29 Derek Atkins <derek@ihtfp.com>
|
||||||
* src/gnome-utils/dialog-exchange.h -- header for the exchange-rate dialog
|
* src/gnome-utils/dialog-exchange.h -- header for the exchange-rate dialog
|
||||||
|
|
||||||
|
@ -48,11 +48,11 @@ gnc_hbci_getbalance (GtkWidget *parent, Account *gnc_acc)
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
api = gnc_hbci_api_new_currentbook (parent, &interactor);
|
api = gnc_hbci_api_new_currentbook (parent, &interactor);
|
||||||
g_assert (interactor);
|
|
||||||
if (api == NULL) {
|
if (api == NULL) {
|
||||||
printf("gnc_hbci_getbalance: Couldn't get HBCI API.\n");
|
printf("gnc_hbci_getbalance: Couldn't get HBCI API.\n");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
g_assert (interactor);
|
||||||
|
|
||||||
h_acc = gnc_hbci_get_hbci_acc (api, gnc_acc);
|
h_acc = gnc_hbci_get_hbci_acc (api, gnc_acc);
|
||||||
if (h_acc == NULL) {
|
if (h_acc == NULL) {
|
||||||
|
@ -63,11 +63,11 @@ gnc_hbci_gettrans (GtkWidget *parent, Account *gnc_acc)
|
|||||||
g_assert(gnc_acc);
|
g_assert(gnc_acc);
|
||||||
|
|
||||||
api = gnc_hbci_api_new_currentbook (parent, &interactor);
|
api = gnc_hbci_api_new_currentbook (parent, &interactor);
|
||||||
g_assert (interactor);
|
|
||||||
if (api == NULL) {
|
if (api == NULL) {
|
||||||
printf("gnc_hbci_gettrans: Couldn't get HBCI API.\n");
|
printf("gnc_hbci_gettrans: Couldn't get HBCI API.\n");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
g_assert (interactor);
|
||||||
|
|
||||||
h_acc = gnc_hbci_get_hbci_acc (api, gnc_acc);
|
h_acc = gnc_hbci_get_hbci_acc (api, gnc_acc);
|
||||||
if (h_acc == NULL) {
|
if (h_acc == NULL) {
|
||||||
|
@ -50,11 +50,11 @@ gnc_hbci_maketrans (GtkWidget *parent, Account *gnc_acc,
|
|||||||
g_assert(gnc_acc);
|
g_assert(gnc_acc);
|
||||||
|
|
||||||
api = gnc_hbci_api_new_currentbook (parent, &interactor);
|
api = gnc_hbci_api_new_currentbook (parent, &interactor);
|
||||||
g_assert (interactor);
|
|
||||||
if (api == NULL) {
|
if (api == NULL) {
|
||||||
printf("gnc_hbci_maketrans: Couldn't get HBCI API. Nothing will happen.\n");
|
printf("gnc_hbci_maketrans: Couldn't get HBCI API. Nothing will happen.\n");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
g_assert (interactor);
|
||||||
|
|
||||||
h_acc = gnc_hbci_get_hbci_acc (api, gnc_acc);
|
h_acc = gnc_hbci_get_hbci_acc (api, gnc_acc);
|
||||||
if (h_acc == NULL) {
|
if (h_acc == NULL) {
|
||||||
|
@ -43,8 +43,17 @@ gnc_hbci_api_new (const char *filename, gboolean allowNewFile,
|
|||||||
if (!filename)
|
if (!filename)
|
||||||
return NULL;
|
return NULL;
|
||||||
if (!allowNewFile &&
|
if (!allowNewFile &&
|
||||||
(!g_file_test (filename, G_FILE_TEST_ISFILE | G_FILE_TEST_ISLINK)))
|
(!g_file_test (filename, G_FILE_TEST_ISFILE | G_FILE_TEST_ISLINK))) {
|
||||||
|
gnc_warning_dialog_parented
|
||||||
|
(parent,
|
||||||
|
/* Translators: Strings from this file are really only needed
|
||||||
|
* inside Germany (HBCI is not supported anywhere else). You
|
||||||
|
* may safely ignore strings from the import-export/hbci
|
||||||
|
* subdirectory in other countries. */
|
||||||
|
_("Error while loading OpenHBCI config file:\n %s: No such file or directory.\n"), filename);
|
||||||
return NULL;
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
api = HBCI_API_new (FALSE, TRUE);
|
api = HBCI_API_new (FALSE, TRUE);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user