diff options
author | Federico Mena Quintero <federico@ximian.com> | 2001-11-12 21:47:34 +0800 |
---|---|---|
committer | Federico Mena Quintero <federico@src.gnome.org> | 2001-11-12 21:47:34 +0800 |
commit | 9dab15ace74f972425b35ce13c6c87ab1e1878a7 (patch) | |
tree | 7da3781158cc900996cc23d6987b5338569bbaa5 /calendar | |
parent | 6a06e2ee66a6bcd538291c92bedc71de1a890f92 (diff) | |
download | gsoc2013-evolution-9dab15ace74f972425b35ce13c6c87ab1e1878a7.tar gsoc2013-evolution-9dab15ace74f972425b35ce13c6c87ab1e1878a7.tar.gz gsoc2013-evolution-9dab15ace74f972425b35ce13c6c87ab1e1878a7.tar.bz2 gsoc2013-evolution-9dab15ace74f972425b35ce13c6c87ab1e1878a7.tar.lz gsoc2013-evolution-9dab15ace74f972425b35ce13c6c87ab1e1878a7.tar.xz gsoc2013-evolution-9dab15ace74f972425b35ce13c6c87ab1e1878a7.tar.zst gsoc2013-evolution-9dab15ace74f972425b35ce13c6c87ab1e1878a7.zip |
The last argument to the bonobo_config_get_XXX_with_default() is a
2001-11-11 Federico Mena Quintero <federico@ximian.com>
* gui/alarm-notify/save.c (get_calendars_to_load): The last
argument to the bonobo_config_get_XXX_with_default() is a gboolean
*, not a CORBA_Environment *. Fixes bug #14655.
svn path=/trunk/; revision=14671
Diffstat (limited to 'calendar')
-rw-r--r-- | calendar/ChangeLog | 6 | ||||
-rw-r--r-- | calendar/gui/alarm-notify/save.c | 23 |
2 files changed, 15 insertions, 14 deletions
diff --git a/calendar/ChangeLog b/calendar/ChangeLog index 6e809e8598..41cf3cf014 100644 --- a/calendar/ChangeLog +++ b/calendar/ChangeLog @@ -1,3 +1,9 @@ +2001-11-11 Federico Mena Quintero <federico@ximian.com> + + * gui/alarm-notify/save.c (get_calendars_to_load): The last + argument to the bonobo_config_get_XXX_with_default() is a gboolean + *, not a CORBA_Environment *. Fixes bug #14655. + 2001-11-11 JP Rosevear <jpr@ximian.com> * pcs/cal-backend-file.c (free_busy_instance): recurrence diff --git a/calendar/gui/alarm-notify/save.c b/calendar/gui/alarm-notify/save.c index 72a52c24fa..a7f70cd740 100644 --- a/calendar/gui/alarm-notify/save.c +++ b/calendar/gui/alarm-notify/save.c @@ -193,7 +193,6 @@ GPtrArray * get_calendars_to_load (void) { Bonobo_ConfigDatabase db; - CORBA_Environment ev; GPtrArray *uris; int len, i; @@ -201,30 +200,26 @@ get_calendars_to_load (void) if (db == CORBA_OBJECT_NIL) return NULL; - /* Get the value */ - - CORBA_exception_init (&ev); + /* Getting the default value below is not necessarily an error, as we + * may not have saved the list of calendar yet. + */ - len = bonobo_config_get_long_with_default (db, KEY_NUM_CALENDARS_TO_LOAD, 0, &ev); - if (ev._major != CORBA_NO_EXCEPTION) { - g_warning ("Cannot read key %s -- %s", KEY_NUM_CALENDARS_TO_LOAD, ev._repo_id); - len = 0; - } + len = bonobo_config_get_long_with_default (db, KEY_NUM_CALENDARS_TO_LOAD, 0, NULL); uris = g_ptr_array_new (); g_ptr_array_set_size (uris, len); for (i = 0; i < len; i++) { char *key; + gboolean used_default; key = g_strdup_printf ("%s%d", BASE_KEY_CALENDAR_TO_LOAD, i); - uris->pdata[i] = bonobo_config_get_string_with_default (db, key, "", &ev); - if (ev._major != NULL) - g_warning ("Cannot read key %s -- %s", key, ev._repo_id); + uris->pdata[i] = bonobo_config_get_string_with_default (db, key, "", &used_default); + if (used_default) + g_message ("get_calendars_to_load(): Could not read calendar name %d", i); + g_free (key); } - CORBA_exception_free (&ev); - return uris; } |