From a7d51125891ff732d853f0462d89c1e052f454df Mon Sep 17 00:00:00 2001 From: Ettore Perazzoli Date: Thu, 24 Aug 2000 04:56:44 +0000 Subject: Don't crash if a component cannot be activated. svn path=/trunk/; revision=4999 --- shell/ChangeLog | 6 ++++++ shell/evolution-shell-component-client.c | 10 ++++++---- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/shell/ChangeLog b/shell/ChangeLog index a05041c9c9..7276359dd1 100644 --- a/shell/ChangeLog +++ b/shell/ChangeLog @@ -1,3 +1,9 @@ +2000-08-24 Ettore Perazzoli + + * evolution-shell-component-client.c + (evolution_shell_component_client_new): Don't abort if the + component cannot be activated. Rather, just return NULL. + 2000-08-20 arik devens * Makefile.am (evolution_LDADD): Added UNICODE_LIBS to link in the diff --git a/shell/evolution-shell-component-client.c b/shell/evolution-shell-component-client.c index c6cb1463dd..bc7c1f9507 100644 --- a/shell/evolution-shell-component-client.c +++ b/shell/evolution-shell-component-client.c @@ -326,14 +326,16 @@ evolution_shell_component_client_new (const char *id) corba_object = oaf_activate_from_id ((char *) id, 0, NULL, &ev); /* Yuck. */ if (ev._major != CORBA_NO_EXCEPTION) { CORBA_exception_free (&ev); - g_error ("Could not start up component for %s. " - "(See previous error messages?)", id); + g_warning ("Could not start up component for %s. " + "(See previous error messages?)", id); + return NULL; } CORBA_exception_free (&ev); if (corba_object == CORBA_OBJECT_NIL) { - g_error ("Could not activate component %s. " - "(Maybe you need to set OAF_INFO_PATH?)", id); + g_warning ("Could not activate component %s. " + "(Maybe you need to set OAF_INFO_PATH?)", id); + return NULL; } new = gtk_type_new (evolution_shell_component_client_get_type ()); -- cgit v1.2.3