[gnome-system-monitor/gtk3: 9/19] Moved rsvg_init and rsvg_term into main to fix Bug #613752.
- From: Chris Kühl <chriskuehl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-system-monitor/gtk3: 9/19] Moved rsvg_init and rsvg_term into main to fix Bug #613752.
- Date: Fri, 11 Feb 2011 15:14:15 +0000 (UTC)
commit 253abb32f437c212af6631f2d609d197e0c6f719
Author: Chris Kühl <chrisk openismus com>
Date: Thu Jan 27 15:20:45 2011 +0100
Moved rsvg_init and rsvg_term into main to fix Bug #613752.
src/gsm_color_button.c | 3 ---
src/procman.cpp | 7 +++++++
2 files changed, 7 insertions(+), 3 deletions(-)
---
diff --git a/src/gsm_color_button.c b/src/gsm_color_button.c
index ef7b3de..e829694 100644
--- a/src/gsm_color_button.c
+++ b/src/gsm_color_button.c
@@ -595,8 +595,6 @@ gsm_color_button_init (GSMColorButton * color_button)
{
color_button->priv = GSM_COLOR_BUTTON_GET_PRIVATE (color_button);
- rsvg_init ();
-
color_button->priv->color.red = 0;
color_button->priv->color.green = 0;
color_button->priv->color.blue = 0;
@@ -645,7 +643,6 @@ gsm_color_button_finalize (GObject * object)
cairo_surface_destroy (color_button->priv->image_buffer);
color_button->priv->image_buffer = NULL;
- rsvg_term ();
G_OBJECT_CLASS (gsm_color_button_parent_class)->finalize (object);
}
diff --git a/src/procman.cpp b/src/procman.cpp
index 19c4cbc..f20de72 100644
--- a/src/procman.cpp
+++ b/src/procman.cpp
@@ -715,6 +715,9 @@ main (int argc, char *argv[])
exit (0);
}
+ /* initialize rsvg */
+ rsvg_init ();
+
gtk_window_set_default_icon_name ("utilities-system-monitor");
g_set_application_name(_("System Monitor"));
@@ -753,6 +756,10 @@ main (int argc, char *argv[])
glibtop_close ();
+ // This function should only be called just before program exit.
+ // See GNOME bug #592100 for a discussion about this.
+ rsvg_term ();
+
return 0;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]