Browse Source

Fixed SD2-1387: Freezing a thread may hang SharpDevelop

git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/trunk@3107 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61
shortcuts
David Srbecký 18 years ago
parent
commit
06766bc96d
  1. 4
      src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Control/Eval.cs

4
src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Control/Eval.cs

@ -97,6 +97,9 @@ namespace Debugger @@ -97,6 +97,9 @@ namespace Debugger
if (!targetThread.IsAtSafePoint) {
throw new GetValueException("Can not evaluate because thread is not at a safe point");
}
if (targetThread.Suspended) {
throw new GetValueException("Can not evaluate on suspended thread");
}
return targetThread.CorThread.CreateEval();
}
@ -135,6 +138,7 @@ namespace Debugger @@ -135,6 +138,7 @@ namespace Debugger
Value WaitForResult()
{
// Note that aborting is not supported for suspended threads
try {
process.WaitForPause(TimeSpan.FromMilliseconds(500));
if (!Evaluated) {

Loading…
Cancel
Save