[balsa] Stop using GSlice; it may go away
- From: Peter Bloomfield <peterb src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [balsa] Stop using GSlice; it may go away
- Date: Fri, 14 Dec 2018 16:04:34 +0000 (UTC)
commit f9b7f772277e62c17340ee8e19cd366b3d18a643
Author: Peter Bloomfield <PeterBloomfield bellsouth net>
Date: Fri Dec 14 10:03:44 2018 -0600
Stop using GSlice; it may go away
* libbalsa/mailbox.c (libbalsa_mailbox_search_iter_new): use
g_new(), not g_slice_new();
(libbalsa_mailbox_search_iter_unref): use g_free(), not
g_slice_free().
ChangeLog | 9 +++++++++
libbalsa/mailbox.c | 4 ++--
2 files changed, 11 insertions(+), 2 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index d6bfd8aaa..6bf1134bb 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2018-12-14 Peter Bloomfield <pbloomfield bellsouth net>
+
+ Stop using GSlice; it may go away
+
+ * libbalsa/mailbox.c (libbalsa_mailbox_search_iter_new): use
+ g_new(), not g_slice_new();
+ (libbalsa_mailbox_search_iter_unref): use g_free(), not
+ g_slice_free().
+
2018-12-13 Albrecht Dreß <albrecht dress arcor de>
Replace readdir() by g_dir_read_name()
diff --git a/libbalsa/mailbox.c b/libbalsa/mailbox.c
index 1d74bfd49..564347a46 100644
--- a/libbalsa/mailbox.c
+++ b/libbalsa/mailbox.c
@@ -1676,7 +1676,7 @@ libbalsa_mailbox_search_iter_new(LibBalsaCondition * condition)
if (!condition)
return NULL;
- iter = g_slice_new(LibBalsaMailboxSearchIter);
+ iter = g_new(LibBalsaMailboxSearchIter, 1);
iter->mailbox = NULL;
iter->stamp = 0;
iter->condition = libbalsa_condition_ref(condition);
@@ -1721,7 +1721,7 @@ libbalsa_mailbox_search_iter_unref(LibBalsaMailboxSearchIter * search_iter)
LIBBALSA_MAILBOX_GET_CLASS(mailbox)->search_iter_free(search_iter);
libbalsa_condition_unref(search_iter->condition);
- g_slice_free(LibBalsaMailboxSearchIter, search_iter);
+ g_free(search_iter);
}
/* GNode iterators; they return the root node when they run out of nodes,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]