gstbin: swap the lines of my previous commit

Fixes a bug introduced in my previous commit that released the
clock provider and after used it to create the clock lost message.
This commit is contained in:
Josep Torra 2009-06-16 18:32:12 +02:00
parent 6103d45dc0
commit d280a3977e

View file

@ -1211,12 +1211,12 @@ gst_bin_remove_func (GstBin * bin, GstElement * element)
if (bin->clock_provider == element) {
GST_DEBUG_OBJECT (bin, "element \"%s\" provided the clock", elem_name);
bin->clock_dirty = TRUE;
clock_message =
gst_message_new_clock_lost (GST_OBJECT_CAST (bin), bin->provided_clock);
provided_clock_p = &bin->provided_clock;
clock_provider_p = &bin->clock_provider;
gst_object_replace ((GstObject **) provided_clock_p, NULL);
gst_object_replace ((GstObject **) clock_provider_p, NULL);
clock_message =
gst_message_new_clock_lost (GST_OBJECT_CAST (bin), bin->provided_clock);
}
/* remove messages for the element, if there was a pending ASYNC_START