Explorar el Código

2009-04-21 Mark Probst <[email protected]>

        * Thread.cs: Make the execution context field thread-static to
        avoid it being shared between app domains.

2009-04-21  Mark Probst  <[email protected]>

        * Environment.cs: Bump corlib version.

svn path=/trunk/mcs/; revision=132308
Mark Probst hace 16 años
padre
commit
322f82badc

+ 5 - 0
mcs/class/corlib/System.Threading/ChangeLog

@@ -1,3 +1,8 @@
+2009-04-21  Mark Probst  <[email protected]>
+
+	* Thread.cs: Make the execution context field thread-static to
+	avoid it being shared between app domains.
+
 2009-04-20  Rolf Bjarne Kvinge  <[email protected]>
 
 	* Thread.cs: For 2.1 ensure exceptions in threads are handled using the

+ 3 - 2
mcs/class/corlib/System.Threading/Thread.cs

@@ -94,7 +94,6 @@ namespace System.Threading {
 		private int serialized_culture_info_len;
 		private IntPtr serialized_ui_culture_info;
 		private int serialized_ui_culture_info_len;
-		private ExecutionContext _ec;
 		private bool thread_dump_requested;
 		private IntPtr end_stack;
 		private bool thread_interrupt_requested;
@@ -119,6 +118,9 @@ namespace System.Threading {
 		[ThreadStatic] 
 		static object[] local_slots;
 
+		[ThreadStatic]
+		static ExecutionContext _ec;
+
 		// can be both a ThreadSart and a ParameterizedThreadStart
 		private MulticastDelegate threadstart;
 		//private string thread_name=null;
@@ -946,7 +948,6 @@ namespace System.Threading {
 		}
 
 		[MonoTODO ("limited to CompressedStack support")]
-		// FIXME: We share the _ec object between appdomains
 		public ExecutionContext ExecutionContext {
 			[ReliabilityContract (Consistency.WillNotCorruptState, Cer.MayFail)]
 			get {

+ 4 - 0
mcs/class/corlib/System/ChangeLog

@@ -1,3 +1,7 @@
+2009-04-21  Mark Probst  <[email protected]>
+
+	* Environment.cs: Bump corlib version.
+
 2009-04-21  Miguel de Icaza  <[email protected]>
 
 	* TermInfoDriver.cs: Prevent race condition if two threads try to

+ 1 - 1
mcs/class/corlib/System/Environment.cs

@@ -63,7 +63,7 @@ namespace System {
 		 * Changes which are already detected at runtime, like the addition
 		 * of icalls, do not require an increment.
 		 */
-		private const int mono_corlib_version = 75;
+		private const int mono_corlib_version = 76;
 
 #if NET_2_0
 		[ComVisible (true)]