Ver código fonte

Keep only 1 Dispose implementation

Marek Safar 15 anos atrás
pai
commit
abd9a33306
1 arquivos alterados com 3 adições e 7 exclusões
  1. 3 7
      mcs/class/corlib/System.Threading/WaitHandle.cs

+ 3 - 7
mcs/class/corlib/System.Threading/WaitHandle.cs

@@ -215,10 +215,12 @@ namespace System.Threading
 
 #if NET_4_0
 		public void Dispose ()
+#else		
+		void IDisposable.Dispose ()
+#endif
 		{
 			Close ();
 		}
-#endif
 
 		public const int WaitTimeout = 258;
 
@@ -402,12 +404,6 @@ namespace System.Threading
 		protected static readonly IntPtr InvalidHandle = (IntPtr) (-1);
 		bool disposed = false;
 
-		void IDisposable.Dispose() {
-			Dispose(true);
-			// Take yourself off the Finalization queue
-			GC.SuppressFinalize(this);
-		}
-		
 		~WaitHandle() {
 			Dispose(false);
 		}