In System.Drawing:
authorGeoff Norton <grompf@sublimeintervention.com>
Fri, 21 Mar 2008 15:07:08 +0000 (15:07 -0000)
committerGeoff Norton <grompf@sublimeintervention.com>
Fri, 21 Mar 2008 15:07:08 +0000 (15:07 -0000)
2008-03-31  Geoff Norton  <gnorton@novell.com>

* carbonFunctions.cs: Disable QDContext caching for now.  It's
causing crashes in the finalizer code.

svn path=/trunk/mcs/; revision=98741

mcs/class/System.Drawing/System.Drawing/ChangeLog
mcs/class/System.Drawing/System.Drawing/carbonFunctions.cs

index e30a21003d58a1db1a132f9a23e543af228de3d7..595215e3d478c1461a3720bcc4e3aa34550baa2f 100644 (file)
@@ -1,3 +1,8 @@
+2008-03-31  Geoff Norton  <gnorton@novell.com>
+
+       * carbonFunctions.cs: Disable QDContext caching for now.  It's
+       causing crashes in the finalizer code.
+
 2008-03-06  Ivan N. Zlatev  <contact@i-nz.net>
 
        * ImageFormatConverter.cs: 
index 984feba3e85d046d2d88588f30f0ff099d6f7490..64a1452eed21513214b8efdbb9b469fd830962ea 100644 (file)
@@ -140,12 +140,16 @@ namespace System.Drawing {
                        IntPtr context = IntPtr.Zero;
 
                        lock (lockobj) { 
+#if FALSE
                                if (contextReference [port] != null) {
                                        CreateCGContextForPort (port, ref context);
                                } else {
                                        QDBeginCGContext (port, ref context);
                                        contextReference [port] = context;
                                }
+#else
+                               CreateCGContextForPort (port, ref context);
+#endif
                        }
 
                        return context;
@@ -155,12 +159,16 @@ namespace System.Drawing {
                        CGContextRestoreGState (context);
 
                        lock (lockobj) { 
+#if FALSE
                                if (contextReference [port] != null && context == (IntPtr) contextReference [port]) { 
                                        QDEndCGContext (port, ref context);
                                        contextReference [port] = null;
                                } else {
                                        CFRelease (context);
                                }
+#else
+                               CFRelease (context);
+#endif
                        }
                }