ges: modifies emission of the track/object-removed signal
authorMathieu Duponchelle <seeed@laposte.net>
Wed, 24 Aug 2011 10:06:22 +0000 (12:06 +0200)
committerThibault Saunier <thibault.saunier@collabora.com>
Wed, 11 Jan 2012 14:56:15 +0000 (11:56 -0300)
Make it be emitted right before the track objects is removed so we don't end up
with a TrackObject that has already been freed

ges/ges-track.c

index 786f028c1a1266165cec1ea7452bb79fe617232a..71ad5c841425279d656c57aa0bf9deef8c5b33ef 100644 (file)
@@ -494,11 +494,12 @@ ges_track_remove_object (GESTrack * track, GESTrackObject * object)
   }
 
   ges_track_object_set_track (object, NULL);
-  priv->trackobjects = g_list_remove (priv->trackobjects, object);
 
   g_signal_emit (track, ges_track_signals[TRACK_OBJECT_REMOVED], 0,
       GES_TRACK_OBJECT (object));
 
+  priv->trackobjects = g_list_remove (priv->trackobjects, object);
+
   g_object_unref (object);
 
   return TRUE;