diff options
Diffstat (limited to 'camel/camel-object.c')
-rw-r--r-- | camel/camel-object.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/camel/camel-object.c b/camel/camel-object.c index daa83284c0..7d6f38a55b 100644 --- a/camel/camel-object.c +++ b/camel/camel-object.c @@ -545,6 +545,14 @@ camel_object_unref (CamelObject * obj) g_slist_free (head); + /* Sanity check */ + + if (obj->ref_count != 0) + g_warning ("camel_object_unref: destroyed object %s at %p somehow got" + " referenced in destruction chain.", + camel_type_to_name (obj->s.type), + obj); + /* A little bit of cleaning up. * Don't erase the type, so we can peek at it if a finalized object |