From 75f7f9ed05585d18e3db0dcd9d00082971261ca9 Mon Sep 17 00:00:00 2001 From: Owen Taylor Date: Mon, 25 Mar 2002 22:26:53 +0000 Subject: [PATCH] Wrap setting freed instance memory to 0xaa in #ifdef G_ENABLE_DEBUG Mon Mar 25 17:25:57 2002 Owen Taylor * gtype.c (g_type_free_instance): Wrap setting freed instance memory to 0xaa in #ifdef G_ENABLE_DEBUG --- gobject/ChangeLog | 5 +++++ gobject/gtype.c | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/gobject/ChangeLog b/gobject/ChangeLog index 242b89c..0c0044e 100644 --- a/gobject/ChangeLog +++ b/gobject/ChangeLog @@ -1,3 +1,8 @@ +Mon Mar 25 17:25:57 2002 Owen Taylor + + * gtype.c (g_type_free_instance): Wrap setting freed instance + memory to 0xaa in #ifdef G_ENABLE_DEBUG + Thu Mar 21 01:28:14 2002 Tim Janik * gsignal.[hc]: diff --git a/gobject/gtype.c b/gobject/gtype.c index 9bb0b91..f419af8 100644 --- a/gobject/gtype.c +++ b/gobject/gtype.c @@ -1377,7 +1377,9 @@ g_type_free_instance (GTypeInstance *instance) } instance->g_class = NULL; - memset (instance, 0xaa, node->data->instance.instance_size); /* FIXME: debugging hack */ +#ifdef G_ENABLE_DEBUG + memset (instance, 0xaa, node->data->instance.instance_size); /* debugging hack */ +#endif if (node->data->instance.n_preallocs) { G_WRITE_LOCK (&type_rw_lock); -- 2.7.4