mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-23 15:48:23 +00:00
vrawdepay: don't access rtp buffer after unmap
Read the marker bit before we unmap the rtp packet.
This commit is contained in:
parent
f0640f205c
commit
9857e6af4d
1 changed files with 3 additions and 1 deletions
|
@ -301,6 +301,7 @@ gst_rtp_vraw_depay_process (GstRTPBaseDepayload * depayload, GstBuffer * buf)
|
|||
gint width, height, xinc, yinc;
|
||||
GstRTPBuffer rtp = { NULL };
|
||||
GstVideoFrame frame;
|
||||
gboolean marker;
|
||||
|
||||
rtpvrawdepay = GST_RTP_VRAW_DEPAY (depayload);
|
||||
|
||||
|
@ -523,9 +524,10 @@ gst_rtp_vraw_depay_process (GstRTPBaseDepayload * depayload, GstBuffer * buf)
|
|||
}
|
||||
|
||||
gst_video_frame_unmap (&frame);
|
||||
marker = gst_rtp_buffer_get_marker (&rtp);
|
||||
gst_rtp_buffer_unmap (&rtp);
|
||||
|
||||
if (gst_rtp_buffer_get_marker (&rtp)) {
|
||||
if (marker) {
|
||||
GST_LOG_OBJECT (depayload, "marker, flushing frame");
|
||||
if (rtpvrawdepay->outbuf) {
|
||||
gst_rtp_base_depayload_push (depayload, rtpvrawdepay->outbuf);
|
||||
|
|
Loading…
Reference in a new issue