[farsight2/master] Save, forget proxies on signals

Olivier Crête olivier.crete at collabora.co.uk
Tue Dec 23 15:24:32 PST 2008


---
 fs-upnp-simple-igd.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/fs-upnp-simple-igd.c b/fs-upnp-simple-igd.c
index caeefcd..964aa05 100644
--- a/fs-upnp-simple-igd.c
+++ b/fs-upnp-simple-igd.c
@@ -204,6 +204,7 @@ _cp_service_avail (GUPnPControlPoint *cp,
     GUPnPServiceProxy *proxy,
     FsUpnpSimpleIgd *self)
 {
+  g_ptr_array_add (self->priv->service_proxies, g_object_ref (proxy));
 }
 
 
@@ -212,6 +213,8 @@ _cp_service_unavail (GUPnPControlPoint *cp,
     GUPnPServiceProxy *proxy,
     FsUpnpSimpleIgd *self)
 {
+  if (g_ptr_array_remove(self->priv->service_proxies, proxy))
+    g_object_unref (proxy);
 }
 
 
-- 
1.5.6.5




More information about the farsight-commits mailing list