Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/debugger-libs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJb Evain <jbevain@microsoft.com>2014-11-20 15:37:18 +0300
committerJb Evain <jbevain@microsoft.com>2014-11-20 15:37:18 +0300
commit48702e1e19bc1fb954a844a9f7bcf38abe1553bf (patch)
treedeb4c62c86370a3a5c691dff6e08009f46a6355a /Mono.Debugging.Soft/SoftEvaluationContext.cs
parent90dc4ac5ea9a57ada4d0c3ef3cd6fd2dab411067 (diff)
[Mono.Debugging.Soft] Use the Domain local to the frame
ThreadMirror.Domain doesn't give you the domain local to the stack frame, as a Thread created in one domain could execute code in multiple domains. We need to use the domain specific to the stack frame.
Diffstat (limited to 'Mono.Debugging.Soft/SoftEvaluationContext.cs')
-rw-r--r--Mono.Debugging.Soft/SoftEvaluationContext.cs7
1 files changed, 6 insertions, 1 deletions
diff --git a/Mono.Debugging.Soft/SoftEvaluationContext.cs b/Mono.Debugging.Soft/SoftEvaluationContext.cs
index 92e39f2..eb553da 100644
--- a/Mono.Debugging.Soft/SoftEvaluationContext.cs
+++ b/Mono.Debugging.Soft/SoftEvaluationContext.cs
@@ -45,7 +45,12 @@ namespace Mono.Debugging.Soft
{
Frame = frame;
Thread = frame.Thread;
- Domain = Thread.Domain;
+
+ if (frame.VirtualMachine.Version.AtLeast (2, 38)) {
+ Domain = frame.Domain;
+ } else {
+ Domain = frame.Method.DeclaringType.GetTypeObject ().Domain;
+ }
string method = frame.Method.Name;
if (frame.Method.DeclaringType != null)