diff options
author | Lluis Sanchez <lluis@xamarin.com> | 2014-07-28 21:35:30 +0400 |
---|---|---|
committer | Lluis Sanchez <lluis@xamarin.com> | 2014-07-28 21:38:14 +0400 |
commit | 79c79df78809d7b6e6c23aa3676bddbfc06391df (patch) | |
tree | 10d1262a7068061b7fe382955f4ddc641f1eb42c /main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.CustomTools | |
parent | e6de2fac6adc80952157a9a973b95fa3e4619f69 (diff) |
[Ide] Fix crash when running custom tools
Fixes bug #21460 - Xamarin Studio hangs with beach ball when building a project
Diffstat (limited to 'main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.CustomTools')
-rw-r--r-- | main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.CustomTools/CustomToolService.cs | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.CustomTools/CustomToolService.cs b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.CustomTools/CustomToolService.cs index 78f2292634..77aec1ec3f 100644 --- a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.CustomTools/CustomToolService.cs +++ b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.CustomTools/CustomToolService.cs @@ -200,10 +200,12 @@ namespace MonoDevelop.Ide.CustomTools } if (result.Errors.Count > 0) { - foreach (CompilerError err in result.Errors) - TaskService.Errors.Add (new Task (file.FilePath, err.ErrorText, err.Column, err.Line, - err.IsWarning? TaskSeverity.Warning : TaskSeverity.Error, - TaskPriority.Normal, file.Project.ParentSolution, file)); + DispatchService.GuiDispatch (delegate { + foreach (CompilerError err in result.Errors) + TaskService.Errors.Add (new Task (file.FilePath, err.ErrorText, err.Column, err.Line, + err.IsWarning? TaskSeverity.Warning : TaskSeverity.Error, + TaskPriority.Normal, file.Project.ParentSolution, file)); + }); } if (broken) |