[glib/finalize-speedups: 4/4] gobject: Speed up finalization
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib/finalize-speedups: 4/4] gobject: Speed up finalization
- Date: Mon, 23 May 2022 10:15:01 +0000 (UTC)
commit 97a70305c6b71e0cf021a8489b80c060741fdb93
Author: Matthias Clasen <mclasen redhat com>
Date: Sun May 22 08:04:51 2022 -0400
gobject: Speed up finalization
Move the warning about finalize-during-construction
to debug-only.
gobject/gobject.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/gobject/gobject.c b/gobject/gobject.c
index 9a951cb85e..f0c24e208c 100644
--- a/gobject/gobject.c
+++ b/gobject/gobject.c
@@ -1215,13 +1215,13 @@ floating_check (GObject *object)
static void
g_object_finalize (GObject *object)
{
+#ifdef G_ENABLE_DEBUG
if (object_in_construction (object))
{
g_critical ("object %s %p finalized while still in-construction",
G_OBJECT_TYPE_NAME (object), object);
}
-#ifdef G_ENABLE_DEBUG
if (floating_check (object))
{
g_critical ("A floating object %s %p was finalized. This means that someone\n"
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]