Skip to content

Commit

Permalink
Change parent class stat change position
Browse files Browse the repository at this point in the history
  • Loading branch information
stefankiesz committed Nov 29, 2023
1 parent 8002fdf commit 3fe16b4
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/gstreamer/gstkvssink.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1609,6 +1609,13 @@ gst_kvs_sink_change_state(GstElement *element, GstStateChange transition) {
case GST_STATE_CHANGE_READY_TO_PAUSED:
gst_collect_pads_start (kvssink->collect);
break;
default:
break;
}

ret = GST_ELEMENT_CLASS (parent_class)->change_state(element, transition);

switch (transition) {
case GST_STATE_CHANGE_PAUSED_TO_READY:
LOG_INFO("Stopping kvssink for " << kvssink->stream_name);
gst_collect_pads_stop (kvssink->collect);
Expand All @@ -1631,8 +1638,6 @@ gst_kvs_sink_change_state(GstElement *element, GstStateChange transition) {
break;
}

ret = GST_ELEMENT_CLASS (parent_class)->change_state(element, transition);

CleanUp:

if (ret != GST_STATE_CHANGE_SUCCESS) {
Expand Down

0 comments on commit 3fe16b4

Please sign in to comment.