diff --git a/gst/rtsp-server/rtsp-address-pool.c b/gst/rtsp-server/rtsp-address-pool.c
index 6bb0956a0eb6fa64acae75b50d454f4ab1e6c01c..026d974dff4065b5145567474be26a3a1a520a29 100644
--- a/gst/rtsp-server/rtsp-address-pool.c
+++ b/gst/rtsp-server/rtsp-address-pool.c
@@ -712,3 +712,63 @@ gst_rtsp_address_pool_has_unicast_addresses (GstRTSPAddressPool * pool)
 
   return has_unicast_addresses;
 }
+
+/**
+ * gst_rtsp_address_pool_is_allocated
+ * @pool: a #GstRTSPAddressPool
+ * @address: The IP address to check
+ * @port: The port to check
+ * @ttl: The ttl
+ *
+ * Used to check if a given address port combination has been allocated from
+ * the pool
+ *
+ * Returns: %TRUE if the address has been allocated from the pool, %FALSE
+ * otherwise
+ */
+gboolean
+gst_rtsp_address_pool_is_allocated (GstRTSPAddressPool * pool,
+    const gchar * address, guint port, guint ttl)
+{
+  GstRTSPAddressPoolPrivate *priv;
+  GList *walk, *next;
+  Addr addr;
+  gboolean result;
+
+  g_return_val_if_fail (GST_IS_RTSP_ADDRESS_POOL (pool), FALSE);
+
+  priv = pool->priv;
+  result = FALSE;
+
+  if (!fill_address (address, port, &addr, (ttl != 0))) {
+    GST_ERROR_OBJECT (pool, "invalid address %s", address);
+    return FALSE;
+  }
+
+  g_mutex_lock (&priv->lock);
+  for (walk = priv->allocated; walk; walk = next) {
+    AddrRange *range;
+
+    range = walk->data;
+    next = walk->next;
+
+    /* Not the right type of address */
+    if (range->min.size != addr.size)
+      continue;
+
+    /* Check if the address is in the interval */
+    if (memcmp (range->min.bytes, addr.bytes, addr.size) > 0 ||
+        memcmp (range->max.bytes, addr.bytes, addr.size) < 0)
+      continue;
+
+    /* Chek if the port is inside the range */
+    if (port < range->min.port || port > range->max.port)
+      continue;
+
+    result = TRUE;
+    break;
+  }
+  g_mutex_unlock (&priv->lock);
+
+  return result;
+}
diff --git a/gst/rtsp-server/rtsp-address-pool.h b/gst/rtsp-server/rtsp-address-pool.h
index 1cf908bbc5563f808cb6f750e4ec4d85a1b910ae..8136b2c34a4ea86cf7f5eae18ecda7da38188344 100644
--- a/gst/rtsp-server/rtsp-address-pool.h
+++ b/gst/rtsp-server/rtsp-address-pool.h
@@ -151,6 +151,10 @@ GstRTSPAddress *       gst_rtsp_address_pool_reserve_address (GstRTSPAddressPool
 
 gboolean               gst_rtsp_address_pool_has_unicast_addresses (GstRTSPAddressPool * pool);
 
+gboolean               gst_rtsp_address_pool_is_allocated (GstRTSPAddressPool * pool,
+                                                              const gchar *address,
+                                                              guint port, guint ttl);
+
 G_END_DECLS
 
 #endif /* __GST_RTSP_ADDRESS_POOL_H__ */
diff --git a/tests/check/gst/addresspool.c b/tests/check/gst/addresspool.c
index d862929f99d72dab5c2d14be3b977571b6d8058b..257be4b83bd44e4abdf4da8d1e39ed901f7b8f3a 100644
--- a/tests/check/gst/addresspool.c
+++ b/tests/check/gst/addresspool.c
@@ -205,6 +205,22 @@ GST_START_TEST (test_pool)
   fail_unless (!strcmp (addr->address, "192.168.1.1"));
   gst_rtsp_address_free (addr);
 
+  fail_unless (gst_rtsp_address_pool_add_range (pool,
+          "233.252.1.1", "233.252.1.3", 5000, 5001, 1));
+  fail_unless (gst_rtsp_address_pool_is_allocated (pool,
+        "233.252.1.1", 5000, 1) == FALSE);
+  addr = gst_rtsp_address_pool_reserve_address (pool,
+      "233.252.1.1", 5000, 1, 1);
+  fail_unless (addr != NULL);
+  fail_unless (gst_rtsp_address_pool_is_allocated (pool,
+        "233.252.1.1", 5000, 1) == TRUE);
+  fail_unless (gst_rtsp_address_pool_is_allocated (pool,
+        "233.252.1.1", 5001, 1) == FALSE);
+  fail_unless (gst_rtsp_address_pool_is_allocated (pool,
+        "233.252.1.2", 5000, 1) == FALSE);
+  gst_rtsp_address_free (addr);
+  gst_rtsp_address_pool_clear (pool);
+
 
   g_object_unref (pool);
 }
