This should not happen and generally means some thread is still running.
https://bugzilla.gnome.org/show_bug.cgi?id=768578
handle_object_destroyed (GstLeaksTracer * self, gpointer object)
{
GST_OBJECT_LOCK (self);
+ if (self->done) {
+ g_warning
+ ("object %p destroyed while the leaks tracer was finalizing. Some threads are still running?",
+ object);
+ goto out;
+ }
+
g_hash_table_remove (self->objects, object);
#ifdef G_OS_UNIX
if (self->removed)
g_hash_table_add (self->removed, object_log_new (object));
#endif /* G_OS_UNIX */
+out:
GST_OBJECT_UNLOCK (self);
}
GHashTableIter iter;
gpointer obj;
+ self->done = TRUE;
+
/* Tracers are destroyed as part of gst_deinit() so now is a good time to
* report all the objects which are still alive. */
leaks = log_leaked (self);
GHashTable *added;
/* Set of owned ObjectLog. Protected by object lock */
GHashTable *removed;
+ gboolean done;
gboolean log_stack_trace;
};