From 6a790cb75a2f1ef3b2bf23a153cdb8237b28ed82 Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Fri, 27 Apr 2007 16:44:17 +0000 Subject: [PATCH] gst/rtsp/gstrtspsrc.c: Ignore ASYNC state messages from the udpsink, it's irrelevant for the parent. Original commit message from CVS: * gst/rtsp/gstrtspsrc.c: (gst_rtspsrc_stream_configure_transport), (gst_rtspsrc_parse_rtpinfo), (gst_rtspsrc_play), (gst_rtspsrc_handle_message): Ignore ASYNC state messages from the udpsink, it's irrelevant for the parent. --- ChangeLog | 8 ++++++++ gst/rtsp/gstrtspsrc.c | 12 +++++++++++- 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index f462fee1ff..7ad0526239 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2007-04-27 Wim Taymans + + * gst/rtsp/gstrtspsrc.c: (gst_rtspsrc_stream_configure_transport), + (gst_rtspsrc_parse_rtpinfo), (gst_rtspsrc_play), + (gst_rtspsrc_handle_message): + Ignore ASYNC state messages from the udpsink, it's irrelevant for the + parent. + 2007-04-27 Wim Taymans * gst/rtp/gstrtpilbcdepay.h: diff --git a/gst/rtsp/gstrtspsrc.c b/gst/rtsp/gstrtspsrc.c index 85966dbdee..64a050a2ca 100644 --- a/gst/rtsp/gstrtspsrc.c +++ b/gst/rtsp/gstrtspsrc.c @@ -2898,7 +2898,7 @@ gst_rtspsrc_play (GstRTSPSrc * src) RTSPMessage request = { 0 }; RTSPMessage response = { 0 }; RTSPResult res; - gchar *rtpinfo; + gchar *rtpinfo, *range; GST_RTSP_STATE_LOCK (src); @@ -2922,6 +2922,11 @@ gst_rtspsrc_play (GstRTSPSrc * src) rtsp_message_unset (&request); + /* parse RTP npt field. This is the current position in the stream (Normal + * Play Time) and should be put in the NEWSEGMENT position field. */ + rtsp_message_get_header (&response, RTSP_HDR_RANGE, &range); + + /* parse the RTP-Info header field (if ANY) to get the base seqnum and timestamp * for the RTP packets. If this is not present, we assume all starts from 0... * FIXME, this is info for the RTP session manager ideally. */ @@ -3099,6 +3104,11 @@ gst_rtspsrc_handle_message (GstBin * bin, GstMessage * message) GST_BIN_CLASS (parent_class)->handle_message (bin, message); break; } + case GST_MESSAGE_ASYNC_START: + case GST_MESSAGE_ASYNC_DONE: + /* ignore messages from our internal sinks */ + gst_message_unref (message); + break; default: { GST_BIN_CLASS (parent_class)->handle_message (bin, message);