Index: gstrtspurl.c
===================================================================
RCS file: /cvs/gstreamer/gst-plugins-base/gst-libs/gst/rtsp/gstrtspurl.c,v
retrieving revision 1.2
diff -u -B -b -p -r1.2 gstrtspurl.c
--- gstrtspurl.c	25 Jul 2007 11:22:30 -0000	1.2
+++ gstrtspurl.c	8 Jan 2009 14:21:05 -0000
@@ -58,6 +58,18 @@
 
 #include "gstrtspurl.h"
 
+GType
+gst_rtsp_url_get_type (void)
+{
+  static GType rtsp_url_type = 0;
+
+  if (G_UNLIKELY (rtsp_url_type == 0)) {
+    rtsp_url_type = g_boxed_type_register_static ("GstRTSPUrl",
+        (GBoxedCopyFunc) gst_rtsp_url_copy, (GBoxedFreeFunc) gst_rtsp_url_free);
+  }
+  return rtsp_url_type;
+}
+
 #define RTSP_PROTO      "rtsp://"
 #define RTSP_PROTO_LEN  7
 #define RTSPU_PROTO     "rtspu://"
@@ -177,6 +189,37 @@ invalid:
 }
 
 /**
+ * gst_rtsp_url_copy:
+ * @url: a #GstRTSPUrl
+ *
+ * Make a copy of @url.
+ *
+ * Returns: a copy of @url. Free with gst_rtsp_url_free () after usage.
+ *
+ * Since: 0.10.22
+ */
+GstRTSPUrl *
+gst_rtsp_url_copy (GstRTSPUrl * url)
+{
+  GstRTSPUrl *res;
+
+  g_return_val_if_fail (url != NULL, NULL);
+
+  res = g_new0 (GstRTSPUrl, 1);
+
+  res->transports = url->transports;
+  res->family = url->family;
+  res->user = g_strdup (url->user);
+  res->passwd = g_strdup (url->passwd);
+  res->host = g_strdup (url->host);
+  res->port = url->port;
+  res->abspath = g_strdup (url->abspath);
+  res->query = g_strdup (url->query);
+
+  return res;
+}
+
+/**
  * gst_rtsp_url_free:
  * @url: a #GstRTSPUrl
  *
Index: gstrtspurl.h
===================================================================
RCS file: /cvs/gstreamer/gst-plugins-base/gst-libs/gst/rtsp/gstrtspurl.h,v
retrieving revision 1.2
diff -u -B -b -p -r1.2 gstrtspurl.h
--- gstrtspurl.h	24 Jul 2007 19:19:33 -0000	1.2
+++ gstrtspurl.h	8 Jan 2009 14:21:05 -0000
@@ -44,6 +44,7 @@
 #define __GST_RTSP_URL_H__
 
 #include <glib.h>
+#include <glib-object.h>
 
 #include <gst/rtsp/gstrtspdefs.h>
 #include <gst/rtsp/gstrtsptransport.h>
@@ -83,7 +84,10 @@ struct _GstRTSPUrl {
   gchar             *query;
 }; 
 
+GType gst_rtsp_url_get_type (void);
+
 GstRTSPResult      gst_rtsp_url_parse           (const gchar *urlstr, GstRTSPUrl **url);
+GstRTSPUrl*        gst_rtsp_url_copy            (GstRTSPUrl *url);
 void               gst_rtsp_url_free            (GstRTSPUrl *url);
 gchar*             gst_rtsp_url_get_request_uri (GstRTSPUrl *url);
 
