do not return SUCCESS if a bin's child can't change state. This fix breaks old gstparse
authorBenjamin Otte <otte@gnome.org>
Tue, 8 Apr 2003 21:50:32 +0000 (21:50 +0000)
committerBenjamin Otte <otte@gnome.org>
Tue, 8 Apr 2003 21:50:32 +0000 (21:50 +0000)
Original commit message from CVS:
do not return SUCCESS if a bin's child can't change state. This fix breaks old gstparse

gst/gstbin.c

index e471963..522fa55 100644 (file)
@@ -707,15 +707,10 @@ gst_bin_change_state (GstElement * element)
 
        gst_element_set_state (child, old_child_state);
        if (GST_ELEMENT_SCHED (child) == GST_ELEMENT_SCHED (element)) {
-          /* reset to what is was */
+          /* try to reset it to what is was */
           GST_STATE_PENDING (element) = old_state;
-         
           gst_bin_change_state (element);
-         /* see if the old state was set */
-         if (GST_STATE (element) == old_state) 
-           return GST_STATE_SUCCESS;
 
-         /* something wacky happened, we can't even go back */
          return GST_STATE_FAILURE;
        }
        break;