concat: Properly propagate seqnum of segment events
authorEdward Hervey <edward@centricular.com>
Fri, 20 Aug 2021 14:34:16 +0000 (16:34 +0200)
committerEdward Hervey <bilboed@bilboed.com>
Fri, 20 Aug 2021 14:35:53 +0000 (16:35 +0200)
Was broken by https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/819

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/871>

plugins/elements/gstconcat.c

index b1156a5..35f68eb 100644 (file)
@@ -541,6 +541,7 @@ gst_concat_sink_event (GstPad * pad, GstObject * parent, GstEvent * event)
       break;
     }
     case GST_EVENT_SEGMENT:{
+      guint32 seqnum = gst_event_get_seqnum (event);
       /* Drop segment event, we create our own one */
       gst_event_copy_segment (event, &spad->segment);
       gst_event_replace (&event, NULL);
@@ -608,7 +609,7 @@ gst_concat_sink_event (GstPad * pad, GstObject * parent, GstEvent * event)
           }
         }
         event = gst_event_new_segment (&segment);
-        gst_event_set_seqnum (event, gst_event_get_seqnum (event));
+        gst_event_set_seqnum (event, seqnum);
 
         g_mutex_unlock (&self->lock);
       }