From 7946860578c2e1c80b87f3f9493e54c7763dfc06 Mon Sep 17 00:00:00 2001 From: Mario Sanchez Prada Date: Tue, 9 Oct 2012 18:01:18 +0200 Subject: Avoid a crash in EphyBookmarksEditor when using WebKit2. Still need to figure out a way to port this to the new WebKit2GTK+ favicons API. https://bugzilla.gnome.org/show_bug.cgi?id=679370 --- src/bookmarks/ephy-bookmarks-editor.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/bookmarks/ephy-bookmarks-editor.c b/src/bookmarks/ephy-bookmarks-editor.c index 8ffd89dcb..8dc057b1e 100644 --- a/src/bookmarks/ephy-bookmarks-editor.c +++ b/src/bookmarks/ephy-bookmarks-editor.c @@ -1495,9 +1495,6 @@ icon_loaded_cb (WebKitFaviconDatabase *database, GAsyncResult *result, GtkTreeRo static void provide_favicon (EphyNode *node, GValue *value, gpointer user_data) { -#ifdef HAVE_WEBKIT2 - /* TODO: Favicons */ -#else const char *page_location; GdkPixbuf *favicon = NULL; @@ -1506,6 +1503,9 @@ provide_favicon (EphyNode *node, GValue *value, gpointer user_data) LOG ("Get favicon for %s", page_location ? page_location : "None"); +#ifdef HAVE_WEBKIT2 + /* TODO: Favicons */ +#else if (page_location) { WebKitFaviconDatabase *database = webkit_get_favicon_database (); @@ -1533,10 +1533,9 @@ provide_favicon (EphyNode *node, GValue *value, gpointer user_data) } } } - +#endif g_value_init (value, GDK_TYPE_PIXBUF); g_value_take_object (value, favicon); -#endif } static void -- cgit v1.2.3