Project

General

Profile

Bug #931 » 0002-gtk-Fix-memory-leaks.patch

S2_6 - Marko Lindqvist, 10/08/2024 08:22 PM

View differences:

client/gui-gtk-2.0/pages.c
static gboolean intro_expose(GtkWidget *w, GdkEventExpose *ev)
{
static PangoLayout *layout;
PangoFontDescription* desc;
static int width, height;
static bool left = FALSE;
......
const char *rev_ver;
layout = pango_layout_new(gdk_pango_context_get());
pango_layout_set_font_description(layout,
pango_font_description_from_string("Sans Bold 10"));
desc = pango_font_description_from_string("Sans Bold 10");
pango_layout_set_font_description(layout, desc);
pango_font_description_free(desc);
rev_ver = fc_git_revision();
client/gui-gtk-3.0/pages.c
static gboolean intro_expose(GtkWidget *w, cairo_t *cr, gpointer *data)
{
static PangoLayout *layout;
PangoFontDescription* desc;
static int width, height;
static bool left = FALSE;
GtkAllocation allocation;
......
const char *rev_ver;
layout = pango_layout_new(gtk_widget_create_pango_context(w));
pango_layout_set_font_description(layout,
pango_font_description_from_string("Sans Bold 10"));
desc = pango_font_description_from_string("Sans Bold 10");
pango_layout_set_font_description(layout, desc);
pango_font_description_free(desc);
rev_ver = fc_git_revision();
client/gui-gtk-3.0/themes.c
fc_snprintf(buf, sizeof(buf), "%s/%s/gtk-3.0/gtk.css", directory,
theme_name);
gtk_css_provider_load_from_file(fc_css_provider, g_file_new_for_path(buf), &error);
gtk_css_provider_load_from_path(fc_css_provider, buf, &error);
if (error) {
g_warning("%s\n", error->message);
client/gui-gtk-3.22/pages.c
static gboolean intro_expose(GtkWidget *w, cairo_t *cr, gpointer *data)
{
static PangoLayout *layout;
PangoFontDescription* desc;
static int width, height;
static bool left = FALSE;
GtkAllocation allocation;
......
const char *rev_ver;
layout = pango_layout_new(gtk_widget_create_pango_context(w));
pango_layout_set_font_description(layout,
pango_font_description_from_string("Sans Bold 10"));
desc = pango_font_description_from_string("Sans Bold 10");
pango_layout_set_font_description(layout, desc);
pango_font_description_free(desc);
rev_ver = fc_git_revision();
client/gui-gtk-3.22/themes.c
fc_snprintf(buf, sizeof(buf), "%s/%s/gtk-3.0/gtk.css", directory,
theme_name);
gtk_css_provider_load_from_file(theme_provider, g_file_new_for_path(buf), &error);
gtk_css_provider_load_from_path(theme_provider, buf, &error);
if (error != NULL) {
g_warning("%s\n", error->message);
(4-4/4)