From a2f85d23ef64b945fb61c446b5c5ef7bd7a5712e Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Thu, 1 Dec 2005 18:06:17 +0000 Subject: [PATCH] Make tests work with slice allocator --- ChangeLog | 5 ++++- ChangeLog.pre-2-10 | 5 ++++- ChangeLog.pre-2-12 | 5 ++++- tests/gobject/ifacecheck.c | 4 +--- 4 files changed, 13 insertions(+), 6 deletions(-) diff --git a/ChangeLog b/ChangeLog index 0d4562bd4..2cd4f350b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,4 +1,7 @@ -2005-12-01 Matthias Clasen +2005-12-01 Matthias Clasen + + * tests/gobject/ifacecheck.c (test_iface_base_init): Don't + double-free base interface members. * tests/Makefile.am: Remove duplicate variable. diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index 0d4562bd4..2cd4f350b 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,4 +1,7 @@ -2005-12-01 Matthias Clasen +2005-12-01 Matthias Clasen + + * tests/gobject/ifacecheck.c (test_iface_base_init): Don't + double-free base interface members. * tests/Makefile.am: Remove duplicate variable. diff --git a/ChangeLog.pre-2-12 b/ChangeLog.pre-2-12 index 0d4562bd4..2cd4f350b 100644 --- a/ChangeLog.pre-2-12 +++ b/ChangeLog.pre-2-12 @@ -1,4 +1,7 @@ -2005-12-01 Matthias Clasen +2005-12-01 Matthias Clasen + + * tests/gobject/ifacecheck.c (test_iface_base_init): Don't + double-free base interface members. * tests/Makefile.am: Remove duplicate variable. diff --git a/tests/gobject/ifacecheck.c b/tests/gobject/ifacecheck.c index 4572deb84..f57189a65 100644 --- a/tests/gobject/ifacecheck.c +++ b/tests/gobject/ifacecheck.c @@ -47,9 +47,7 @@ struct _TestIfaceClass static void test_iface_base_init (TestIfaceClass *iface) { - if (iface->history) - g_string_free (iface->history, TRUE); - iface->history = g_string_new (NULL); + iface->history = g_string_new (iface->history ? iface->history->str : NULL); } static DEFINE_IFACE(TestIface, test_iface, test_iface_base_init, NULL)