From 4a74b1ff15ca5cbc175c8fb98839960f1af494fb Mon Sep 17 00:00:00 2001 From: Iain Holmes Date: Fri, 8 Dec 2000 00:00:15 +0000 Subject: New and improved display, Bug fixes memory leaks removed Preferences and probably more that I can't remember. svn path=/trunk/; revision=6858 --- executive-summary/test-service/main.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'executive-summary/test-service/main.c') diff --git a/executive-summary/test-service/main.c b/executive-summary/test-service/main.c index 5b8fdd7b85..1dcbf20b51 100644 --- a/executive-summary/test-service/main.c +++ b/executive-summary/test-service/main.c @@ -154,7 +154,7 @@ static void component_destroyed (GtkObject *object, gpointer data) { - UserData *ud = (UserData *) ud; + UserData *ud = (UserData *) data; /* Free the UserData structure */ g_free (ud->title); g_free (ud->icon); @@ -163,8 +163,10 @@ component_destroyed (GtkObject *object, running_views--; g_print ("Destroy!\n"); - if (running_views <= 0) + if (running_views <= 0) { + bonobo_object_unref (BONOBO_OBJECT (factory)); gtk_main_quit (); + } } static BonoboObject * @@ -225,12 +227,12 @@ create_view (ExecutiveSummaryComponentFactory *_factory, /* Now add the interface */ bonobo_object_add_interface (component, bag); - /* Add the Bonobo::PersistStream interface */ stream = bonobo_persist_stream_new (load_from_stream, save_to_stream, NULL, content_types, NULL); bonobo_object_add_interface (component, stream); + running_views++; /* Return the ExecutiveSummaryComponent object */ return component; } -- cgit v1.2.3