GstEnginePipeline: Always set state to NULL

This commit is contained in:
Jonas Kvinge 2024-11-09 19:26:39 +01:00
parent 64a9d557a4
commit a0dd2c66e4
1 changed files with 2 additions and 3 deletions

View File

@ -179,9 +179,8 @@ GstEnginePipeline::~GstEnginePipeline() {
Disconnect();
if (pipeline_) {
if (state() != GST_STATE_NULL) {
gst_element_set_state(pipeline_, GST_STATE_NULL);
}
gst_element_set_state(pipeline_, GST_STATE_NULL);
GstElement *audiobin = nullptr;
g_object_get(GST_OBJECT(pipeline_), "audio-sink", &audiobin, nullptr);