From: Lutz Mueller Date: Thu, 11 Jan 2007 09:30:59 +0000 (+0000) Subject: gst/rtsp/gstrtspsrc.c: Check for stream pad before activating. X-Git-Tag: RELEASE-0_10_6~389 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=cfed610d01fe602144fce98ad09610d19c877807;p=platform%2Fupstream%2Fgst-plugins-good.git gst/rtsp/gstrtspsrc.c: Check for stream pad before activating. Original commit message from CVS: Patch by: Lutz Mueller * gst/rtsp/gstrtspsrc.c: (gst_rtspsrc_activate_streams): Check for stream pad before activating. --- diff --git a/ChangeLog b/ChangeLog index 7ce3f28bb..6f76f8cbd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2007-01-11 Wim Taymans + + Patch by: Lutz Mueller + + * gst/rtsp/gstrtspsrc.c: (gst_rtspsrc_activate_streams): + Check for stream pad before activating. + 2007-01-10 Wim Taymans Patch by: Peter Kjellerstedt diff --git a/gst/rtsp/gstrtspsrc.c b/gst/rtsp/gstrtspsrc.c index 1ec70b881..96fd79ee6 100644 --- a/gst/rtsp/gstrtspsrc.c +++ b/gst/rtsp/gstrtspsrc.c @@ -1122,11 +1122,13 @@ gst_rtspsrc_activate_streams (GstRTSPSrc * src) for (walk = src->streams; walk; walk = g_list_next (walk)) { GstRTSPStream *stream = (GstRTSPStream *) walk->data; - gst_pad_set_active (stream->srcpad, TRUE); - /* add the pad */ - if (!stream->added) { - gst_element_add_pad (GST_ELEMENT_CAST (src), stream->srcpad); - stream->added = TRUE; + if (stream->srcpad) { + gst_pad_set_active (stream->srcpad, TRUE); + /* add the pad */ + if (!stream->added) { + gst_element_add_pad (GST_ELEMENT_CAST (src), stream->srcpad); + stream->added = TRUE; + } } }