[epiphany] bookmarks-manager: Ref bookmarks in get_smart_bookmarks
- From: Michael Catanzaro <mcatanzaro src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [epiphany] bookmarks-manager: Ref bookmarks in get_smart_bookmarks
- Date: Tue, 1 Nov 2016 16:46:11 +0000 (UTC)
commit 09170308b8ee326f5c90f3ea72a7017b563cf147
Author: Michael Catanzaro <mcatanzaro gnome org>
Date: Tue Nov 1 11:44:19 2016 -0500
bookmarks-manager: Ref bookmarks in get_smart_bookmarks
The container owns the reference; this fixes a memory corruption issue.
src/bookmarks/ephy-bookmarks-manager.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/bookmarks/ephy-bookmarks-manager.c b/src/bookmarks/ephy-bookmarks-manager.c
index f7b3320..c4bae2c 100644
--- a/src/bookmarks/ephy-bookmarks-manager.c
+++ b/src/bookmarks/ephy-bookmarks-manager.c
@@ -571,7 +571,7 @@ ephy_bookmarks_manager_get_smart_bookmarks (EphyBookmarksManager *self)
if (ephy_bookmark_is_smart (bookmark)) {
g_sequence_insert_sorted (bookmarks,
- bookmark,
+ g_object_ref (bookmark),
(GCompareDataFunc)compare_smart_bookmarks,
NULL);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]