gst/rtsp/gstrtspsrc.c: Don't try to configure RTCP back to the server when the server...
authorWim Taymans <wim.taymans@gmail.com>
Wed, 20 Aug 2008 11:48:46 +0000 (11:48 +0000)
committerWim Taymans <wim.taymans@gmail.com>
Wed, 20 Aug 2008 11:48:46 +0000 (11:48 +0000)
Original commit message from CVS:
* gst/rtsp/gstrtspsrc.c: (gst_rtspsrc_stream_configure_udp_sink):
Don't try to configure RTCP back to the server when the server did not
give us a valid port number.

ChangeLog
gst/rtsp/gstrtspsrc.c

index 587c0fb06bb3c68fae2cf526a0919ad4ded3fc47..7b1cc1503611aea0917b11588a7c511e95fb22b6 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2008-08-20  Wim Taymans  <wim.taymans@collabora.co.uk>
+
+       * gst/rtsp/gstrtspsrc.c: (gst_rtspsrc_stream_configure_udp_sink):
+       Don't try to configure RTCP back to the server when the server did not
+       give us a valid port number.
+
 2008-08-20  Wim Taymans  <wim.taymans@collabora.co.uk>
 
        * gst/videobox/gstvideobox.c: (gst_video_box_set_property):
index 46850833c99f6eb0337756ed5a7b7e06270b2676..048786b56921213cc4c9f470d2a9a9bf8efc72ba 100644 (file)
@@ -2057,6 +2057,11 @@ gst_rtspsrc_stream_configure_udp_sink (GstRTSPSrc * src, GstRTSPStream * stream,
   else
     port = transport->server_port.max;
 
+  /* it's possible that the server does not want us to send RTCP in which case
+   * the port is -1 */
+  if (port == -1)
+    goto no_port;
+
   /* first take the source, then the endpoint to figure out where to send
    * the RTCP. */
   destination = transport->source;
@@ -2114,6 +2119,11 @@ no_sink_element:
     GST_DEBUG_OBJECT (src, "no UDP sink element found");
     return FALSE;
   }
+no_port:
+  {
+    GST_DEBUG_OBJECT (src, "no valid port, ignoring RTCP for this stream");
+    return TRUE;
+  }
 }
 
 /* sets up all elements needed for streaming over the specified transport.