ges_track_object_set_timeline_object (res, object);
GST_DEBUG ("Adding TrackObject to the list of controlled track objects");
- object->trackobjects =
- g_list_append (object->trackobjects, g_object_ref (res));
+ /* We steal the initial reference */
+ object->trackobjects = g_list_append (object->trackobjects, res);
GST_DEBUG ("Setting properties on newly created TrackObject");
fail_unless (trackobject != NULL);
/* The track holds a reference to the object */
- ASSERT_OBJECT_REFCOUNT (trackobject, "Track Object", 2);
+ ASSERT_OBJECT_REFCOUNT (trackobject, "Track Object", 1);
fail_unless (ges_timeline_object_release_track_object (GES_TIMELINE_OBJECT
(source), trackobject) == TRUE);
- ASSERT_OBJECT_REFCOUNT (trackobject, "Track Object", 1);
-
g_object_unref (source);
g_object_unref (track);
}