try catch on long running task
don't crash subtract cancel
This commit is contained in:
parent
8b49a3e898
commit
d2b5bd0a44
2 changed files with 12 additions and 1 deletions
|
|
@ -1453,7 +1453,14 @@ namespace MatterHackers.MatterControl
|
|||
|
||||
return Task.Run(async () =>
|
||||
{
|
||||
await func?.Invoke(taskDetails, tokenSource.Token);
|
||||
try
|
||||
{
|
||||
await func?.Invoke(taskDetails, tokenSource.Token);
|
||||
}
|
||||
catch
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
executingTasks.Remove(taskDetails);
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue