client: Configure transport after creating session media
authorLinus Svensson <linussn@axis.com>
Fri, 24 Oct 2014 10:04:54 +0000 (12:04 +0200)
committerWim Taymans <wtaymans@redhat.com>
Fri, 7 Nov 2014 11:42:48 +0000 (12:42 +0100)
The default implementation of configure_client_transport() in
rtsp-client uses the session media when it chooses channels for
interleaved traffic.

https://bugzilla.gnome.org/show_bug.cgi?id=739112

gst/rtsp-server/rtsp-client.c

index c26bf6c..c50444c 100644 (file)
@@ -1810,10 +1810,6 @@ handle_setup_request (GstRTSPClient * client, GstRTSPContext * ctx)
   if (!parse_transport (transport, stream, ct))
     goto unsupported_transports;
 
-  /* update the client transport */
-  if (!klass->configure_client_transport (client, ctx, ct))
-    goto unsupported_client_transport;
-
   /* parse the keymgmt */
   if (gst_rtsp_message_get_header (ctx->request, GST_RTSP_HDR_KEYMGMT,
           &keymgmt, 0) == GST_RTSP_OK) {
@@ -1841,6 +1837,10 @@ handle_setup_request (GstRTSPClient * client, GstRTSPContext * ctx)
 
   ctx->sessmedia = sessmedia;
 
+  /* update the client transport */
+  if (!klass->configure_client_transport (client, ctx, ct))
+    goto unsupported_client_transport;
+
   /* set in the session media transport */
   trans = gst_rtsp_session_media_set_transport (sessmedia, stream, ct);