Always set state to NULL in destructor

This commit is contained in:
Jonas Kvinge 2020-10-21 00:32:55 +02:00
parent 95ac85f642
commit 617179f0c6
1 changed files with 1 additions and 2 deletions

View File

@ -142,8 +142,7 @@ GstEnginePipeline::~GstEnginePipeline() {
gst_object_unref(bus);
}
if (state() != GST_STATE_NULL)
gst_element_set_state(pipeline_, GST_STATE_NULL);
gst_element_set_state(pipeline_, GST_STATE_NULL);
gst_object_unref(GST_OBJECT(pipeline_));