diff options
-rw-r--r-- | src/gsm_color_button.c | 2 | ||||
-rw-r--r-- | src/gsm_color_button.h | 2 | ||||
-rw-r--r-- | src/procman.cpp | 9 |
3 files changed, 5 insertions, 8 deletions
diff --git a/src/gsm_color_button.c b/src/gsm_color_button.c index e8eb320..0d69889 100644 --- a/src/gsm_color_button.c +++ b/src/gsm_color_button.c @@ -251,7 +251,7 @@ fill_image_buffer_from_file (cairo_t *cr, const char *filePath) tmp_cr = cairo_create (tmp_surface); rsvg_handle_render_cairo (handle, tmp_cr); cairo_destroy (tmp_cr); - rsvg_handle_free (handle); + g_object_unref (handle); return tmp_surface; } diff --git a/src/gsm_color_button.h b/src/gsm_color_button.h index ac8d87e..0194887 100644 --- a/src/gsm_color_button.h +++ b/src/gsm_color_button.h @@ -27,7 +27,9 @@ #include <gtk/gtk.h> #include <cairo.h> #include <librsvg/rsvg.h> +#ifndef RSVG_CAIRO_H #include <librsvg/rsvg-cairo.h> +#endif G_BEGIN_DECLS /* The GtkColorSelectionButton widget is a simple color picker in a button. diff --git a/src/procman.cpp b/src/procman.cpp index 14f3465..c534f8d 100644 --- a/src/procman.cpp +++ b/src/procman.cpp @@ -196,7 +196,7 @@ color_changed_cb (GSettings *settings, const gchar *key, gpointer data) if (has_key (keys, key)) color = g_settings_get_string (settings, key); else - color = "#FFFFFF"; /* white default color */ + color = g_strdup("#FFFFFF"); /* white default color */ g_strfreev (keys); if (g_str_has_prefix (key, "cpu-color")) { @@ -721,8 +721,7 @@ main (int argc, char *argv[]) exit (0); } - /* initialize rsvg */ - rsvg_init (); + g_type_init (); gtk_window_set_default_icon_name ("utilities-system-monitor"); g_set_application_name(_("System Monitor")); @@ -761,10 +760,6 @@ main (int argc, char *argv[]) glibtop_close (); - // This function should only be called just before program exit. - // See MATE bug #592100 for a discussion about this. - rsvg_term (); - return 0; } |