From 5d3168e5582dba7c7fd0e849314233e4d5eb452c Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Sun, 24 May 2009 16:33:42 +0200 Subject: rtspsrc: don't send teardown before setup Don't send a TEARDOWN request when we did not manage to successfully setup a stream. --- gst/rtsp/gstrtspsrc.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'gst/rtsp') diff --git a/gst/rtsp/gstrtspsrc.c b/gst/rtsp/gstrtspsrc.c index feab0d71..93af6c62 100644 --- a/gst/rtsp/gstrtspsrc.c +++ b/gst/rtsp/gstrtspsrc.c @@ -4709,6 +4709,10 @@ gst_rtspsrc_close (GstRTSPSrc * src) GST_DEBUG_OBJECT (src, "not connected, doing cleanup"); goto close; } + if (src->state < GST_RTSP_STATE_READY) { + GST_DEBUG_OBJECT (src, "not ready, doing cleanup"); + goto close; + } if (src->methods & (GST_RTSP_PLAY | GST_RTSP_TEARDOWN)) { /* do TEARDOWN */ -- cgit