[tomboy] [WebSyncService] Prevent a crash in the libproxy finalizer	on Windows
- From: Benjamin Podszun <bpodszun src gnome org>
- To: commits-list gnome org
- Cc: 
- Subject: [tomboy] [WebSyncService] Prevent a crash in the libproxy finalizer	on Windows
- Date: Mon,  4 Oct 2010 19:06:53 +0000 (UTC)
commit 3433f19c1e880c307b1f9b2b0ad79d962b4988bd
Author: Jeff V Stein <jeff jeffvstein org>
Date:   Mon Oct 4 21:05:23 2010 +0200
    [WebSyncService] Prevent a crash in the libproxy finalizer on Windows
 Tomboy/Addins/WebSyncService/LibProxy/LibProxy.cs |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/Tomboy/Addins/WebSyncService/LibProxy/LibProxy.cs b/Tomboy/Addins/WebSyncService/LibProxy/LibProxy.cs
index 1a46ef7..26c7687 100644
--- a/Tomboy/Addins/WebSyncService/LibProxy/LibProxy.cs
+++ b/Tomboy/Addins/WebSyncService/LibProxy/LibProxy.cs
@@ -76,8 +76,14 @@ namespace LibProxy {
                 
                 ~ProxyFactory()
                 {
+                    try {
                         // TODO: See note above...
                         px_proxy_factory_free(this.self);
+                    }
+                    catch (DllNotFoundException)
+                    {
+                        // Couldn't load LibProxy previously, prevent failure on GC
+                    }
                 }
         }
 }
[
Date Prev][
Date Next]   [
Thread Prev][
Thread Next]   
[
Thread Index]
[
Date Index]
[
Author Index]