aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/cal-client/cal-client.c
diff options
context:
space:
mode:
authorRodrigo Moya <rodrigo@ximian.com>2001-09-28 17:49:26 +0800
committerRodrigo Moya <rodrigo@src.gnome.org>2001-09-28 17:49:26 +0800
commite09413bd279eed109a34e6d7c2abc68a237ac53d (patch)
tree22fe137201360643e0b8e38467240b70383e31c4 /calendar/cal-client/cal-client.c
parentcf95717637b761affe79cc9ede469ddc90f010fe (diff)
downloadgsoc2013-evolution-e09413bd279eed109a34e6d7c2abc68a237ac53d.tar
gsoc2013-evolution-e09413bd279eed109a34e6d7c2abc68a237ac53d.tar.gz
gsoc2013-evolution-e09413bd279eed109a34e6d7c2abc68a237ac53d.tar.bz2
gsoc2013-evolution-e09413bd279eed109a34e6d7c2abc68a237ac53d.tar.lz
gsoc2013-evolution-e09413bd279eed109a34e6d7c2abc68a237ac53d.tar.xz
gsoc2013-evolution-e09413bd279eed109a34e6d7c2abc68a237ac53d.tar.zst
gsoc2013-evolution-e09413bd279eed109a34e6d7c2abc68a237ac53d.zip
use bonobo-exception for exceptions (cal_client_open_calendar): likewise
2001-09-28 Rodrigo Moya <rodrigo@ximian.com> * cal-client/cal-client.c (cal_client_construct): use bonobo-exception for exceptions (cal_client_open_calendar): likewise svn path=/trunk/; revision=13211
Diffstat (limited to 'calendar/cal-client/cal-client.c')
-rw-r--r--calendar/cal-client/cal-client.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/calendar/cal-client/cal-client.c b/calendar/cal-client/cal-client.c
index 60e8ae7840..86b3cc8a05 100644
--- a/calendar/cal-client/cal-client.c
+++ b/calendar/cal-client/cal-client.c
@@ -632,7 +632,7 @@ cal_client_construct (CalClient *client)
factory = (GNOME_Evolution_Calendar_CalFactory)
oaf_activate_from_id (info->iid, 0, NULL, &ev);
- if (ev._major != CORBA_NO_EXCEPTION) {
+ if (BONOBO_EX (&ev)) {
g_warning ("cal_client_construct: Could not activate calendar server %s", info->iid);
CORBA_free (servers);
CORBA_exception_free (&ev);
@@ -759,14 +759,19 @@ cal_client_open_calendar (CalClient *client, const char *str_uri, gboolean only_
GNOME_Evolution_Calendar_CalFactory_open (f->data, str_uri,
only_if_exists,
corba_listener, &ev);
- if (ev._major == CORBA_NO_EXCEPTION)
+ if (!BONOBO_EX (&ev))
break;
}
if (BONOBO_EX (&ev)) {
CORBA_exception_free (&ev);
- g_message ("cal_client_open_calendar(): open request failed");
+ if (BONOBO_USER_EX (&ev, ex_GNOME_Evolution_Calendar_CalFactory_InvalidURI))
+ g_message ("cal_client_open_calendar: invalid URI");
+ else if (BONOBO_USER_EX (&ev, ex_GNOME_Evolution_Calendar_CalFactory_UnsupportedMethod))
+ g_message ("cal_client_open_calendar: unsupported method");
+ else
+ g_message ("cal_client_open_calendar(): open request failed");
bonobo_object_unref (BONOBO_OBJECT (priv->listener));
priv->listener = NULL;
priv->load_state = CAL_CLIENT_LOAD_NOT_LOADED;