Sfoglia il codice sorgente

[corlib] Fixes build with old UnmanagedMemoryStream

Marek Safar 11 anni fa
parent
commit
cfbb82b747

+ 1 - 1
mcs/class/corlib/System.IO/UnmanagedMemoryStream.cs

@@ -41,7 +41,7 @@ namespace System.IO
 	public class UnmanagedMemoryStream : Stream
 	{
 		long length;
-		bool closed;
+		internal bool closed;
 		long capacity;
 		FileAccess fileaccess;
 		IntPtr initial_pointer;

+ 1 - 1
mcs/class/corlib/System.Reflection/Assembly.cs

@@ -70,7 +70,7 @@ namespace System.Reflection {
 
 			protected override void Dispose (bool disposing)
 			{
-				if (_isOpen) {
+				if (!closed) {
 					/* 
 					 * The returned pointer points inside metadata, so
 					 * we have to increase the refcount of the module, and decrease

+ 1 - 1
mcs/class/corlib/System.Resources/ResourceReader.cs

@@ -109,7 +109,7 @@ namespace System.Resources
 
 			protected override void Dispose (bool disposing)
 			{
-				if (_isOpen) {
+				if (!closed) {
 					Marshal.FreeHGlobal (ptr);
 				}