Author: miguel
Date: 2007-07-18 20:16:20 -0400 (Wed, 18 Jul 2007)
New Revision: 82259

Modified:
   trunk/mcs/class/corlib/Microsoft.Win32.SafeHandles/ChangeLog
   trunk/mcs/class/corlib/Microsoft.Win32.SafeHandles/SafeFileHandle.cs
   trunk/mcs/class/corlib/Microsoft.Win32.SafeHandles/SafeWaitHandle.cs
Log:
2007-07-18  Miguel de Icaza  <[EMAIL PROTECTED]>

        * SafeWaitHandle.cs: Do not call DangerousGetHandle here as it
        throws ObjectDisposedException when the refcount reaches zero. 

        * SafeFileHandle.cs: Same.

Modified: trunk/mcs/class/corlib/Microsoft.Win32.SafeHandles/ChangeLog
===================================================================
--- trunk/mcs/class/corlib/Microsoft.Win32.SafeHandles/ChangeLog        
2007-07-18 23:54:06 UTC (rev 82258)
+++ trunk/mcs/class/corlib/Microsoft.Win32.SafeHandles/ChangeLog        
2007-07-19 00:16:20 UTC (rev 82259)
@@ -1,3 +1,10 @@
+2007-07-18  Miguel de Icaza  <[EMAIL PROTECTED]>
+
+       * SafeWaitHandle.cs: Do not call DangerousGetHandle here as it
+       throws ObjectDisposedException when the refcount reaches zero. 
+
+       * SafeFileHandle.cs: Same.
+
 2007-05-12  Jonathan Chambers  <[EMAIL PROTECTED]>
 
        * SafeWaitHandle.cs: Add internal empty

Modified: trunk/mcs/class/corlib/Microsoft.Win32.SafeHandles/SafeFileHandle.cs
===================================================================
--- trunk/mcs/class/corlib/Microsoft.Win32.SafeHandles/SafeFileHandle.cs        
2007-07-18 23:54:06 UTC (rev 82258)
+++ trunk/mcs/class/corlib/Microsoft.Win32.SafeHandles/SafeFileHandle.cs        
2007-07-19 00:16:20 UTC (rev 82259)
@@ -49,7 +49,7 @@
                {
                        MonoIOError error;
                        
-                       MonoIO.Close (DangerousGetHandle (), out error);
+                       MonoIO.Close (handle, out error);
 
                        return error == MonoIOError.ERROR_SUCCESS;
                }

Modified: trunk/mcs/class/corlib/Microsoft.Win32.SafeHandles/SafeWaitHandle.cs
===================================================================
--- trunk/mcs/class/corlib/Microsoft.Win32.SafeHandles/SafeWaitHandle.cs        
2007-07-18 23:54:06 UTC (rev 82258)
+++ trunk/mcs/class/corlib/Microsoft.Win32.SafeHandles/SafeWaitHandle.cs        
2007-07-19 00:16:20 UTC (rev 82259)
@@ -45,7 +45,7 @@
 
                protected override bool ReleaseHandle ()
                {
-                       NativeEventCalls.CloseEvent_internal 
(DangerousGetHandle ());
+                       NativeEventCalls.CloseEvent_internal (handle);
                        return true;
                }
 

_______________________________________________
Mono-patches maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches

Reply via email to