Please do not reply to this email- if you want to comment on the bug, go to the URL shown below and enter your comments there.
Changed by [EMAIL PROTECTED] http://bugzilla.ximian.com/show_bug.cgi?id=82134 --- shadow/82134 2007-07-18 12:14:31.000000000 -0400 +++ shadow/82134.tmp.559 2007-07-18 17:31:50.000000000 -0400 @@ -1,14 +1,14 @@ Bug#: 82134 Product: Mono: Compilers Version: 1.2 -OS: +OS: unknown OS Details: 2.6 Linux Status: NEW Resolution: -Severity: +Severity: Unknown Priority: Major Component: C# AssignedTo: [EMAIL PROTECTED] ReportedBy: [EMAIL PROTECTED] QAContact: [EMAIL PROTECTED] TargetMilestone: --- @@ -46,6 +46,58 @@ Expected Results: gmcs should not explode How often does this happen? Every time + +------- Additional Comments From [EMAIL PROTECTED] 2007-07-18 17:31 ------- +Fix developed independently at these two threads... +http://lists.ximian.com/pipermail/mono-devel-list/2007-July/024155.html +http://lists.ximian.com/pipermail/mono-devel-list/2007-July/024156.html + +I borrowed the fix from Cedric as I think his version is safer and +already in patch format... + +Thanks Cedric for assisting! + +Index: class/corlib/System.Threading/WaitHandle.cs +=================================================================== +--- class/corlib/System.Threading/WaitHandle.cs (révision 82236) ++++ class/corlib/System.Threading/WaitHandle.cs (copie de travail) +@@ -221,12 +221,7 @@ + [SecurityPermission +(SecurityAction.LinkDemand, UnmanagedCode = true)] + [SecurityPermission +(SecurityAction.InheritanceDemand, UnmanagedCode = true)] + set { +- // +- // Notice, from the 2.x documentation: +- // Assigning a new value to the +Handle property, will not release +- // the previous handle, this could +lead to a leak +- // +- safe_wait_handle = new SafeWaitHandle +(value, false); ++ safe_wait_handle = new SafeWaitHandle +(value, true); + } + } + +Index: class/corlib/System.Runtime.InteropServices/SafeHandle.cs +=================================================================== +--- class/corlib/System.Runtime.InteropServices/SafeHandle.cs +(révision 82236) ++++ class/corlib/System.Runtime.InteropServices/SafeHandle.cs (copie +de travail) +@@ -124,7 +124,7 @@ + [ReliabilityContract (Consistency.WillNotCorruptState, +Cer.Success)] + public IntPtr DangerousGetHandle () + { +- if (refcount == 0){ ++ if (refcount == 0 && handle == +invalid_handle_value) { + throw new ObjectDisposedException +(GetType ().FullName); + }
_______________________________________________ mono-bugs maillist - [email protected] http://lists.ximian.com/mailman/listinfo/mono-bugs
