From: Alessandro Decina Date: Wed, 5 Mar 2014 10:39:09 +0000 (+0100) Subject: rtspsrc: fix seeking X-Git-Tag: 1.3.1~178 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c4bf6e8b7e653f29e3c7d702c6cd5dca457df435;p=platform%2Fupstream%2Fgst-plugins-good.git rtspsrc: fix seeking Call gst_rtspsrc_connection_flush (src, FALSE) to reset connections as non-flushing before sending PAUSE and PLAY with the new npt range. Without this patch, those commands would fail with EINTR as the connections were still flushing. --- diff --git a/gst/rtsp/gstrtspsrc.c b/gst/rtsp/gstrtspsrc.c index 3084087..8eb39e8 100644 --- a/gst/rtsp/gstrtspsrc.c +++ b/gst/rtsp/gstrtspsrc.c @@ -295,6 +295,7 @@ static gboolean gst_rtspsrc_loop (GstRTSPSrc * src); static gboolean gst_rtspsrc_stream_push_event (GstRTSPSrc * src, GstRTSPStream * stream, GstEvent * event); static gboolean gst_rtspsrc_push_event (GstRTSPSrc * src, GstEvent * event); +static void gst_rtspsrc_connection_flush (GstRTSPSrc * src, gboolean flush); typedef struct { @@ -2239,6 +2240,9 @@ gst_rtspsrc_perform_seek (GstRTSPSrc * src, GstEvent * event) GST_DEBUG_OBJECT (src, "stopped streaming"); + /* stop flushing the rtsp connection so we can send PAUSE/PLAY below */ + gst_rtspsrc_connection_flush (src, FALSE); + /* copy segment, we need this because we still need the old * segment when we close the current segment. */ memcpy (&seeksegment, &src->segment, sizeof (GstSegment));