From d29fa60f976abfa37f6da3c4c48880eab4d8687b Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Thu, 11 Mar 2010 12:56:11 +0100 Subject: [PATCH] rtspsrc: check for NULL before doing strcmp Check the connection and address type for NULL before doing strcmp and crashing. Fixes #612553 --- gst/rtsp/gstrtspsrc.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/gst/rtsp/gstrtspsrc.c b/gst/rtsp/gstrtspsrc.c index 3048bd2..59302b1 100644 --- a/gst/rtsp/gstrtspsrc.c +++ b/gst/rtsp/gstrtspsrc.c @@ -808,7 +808,10 @@ static void gst_rtspsrc_do_stream_connection (GstRTSPSrc * src, GstRTSPStream * stream, const GstSDPConnection * conn) { - if (strcmp (conn->nettype, "IN") != 0) + if (conn->nettype == NULL || strcmp (conn->nettype, "IN") != 0) + return; + + if (conn->addrtype == NULL) return; /* check for IPV6 */ -- 2.7.4