Commit d772b6a
Dean Ward
Fix an unobserved task exception (#188)
* Fix an unobserved task exception
Addresses an unobserved exception that occurs when an `ObjectDisposedException` is raised after a `CancellationToken` is cancelled by only cancelling if the token has not been previously cancelled. The default `catch` will fire for an `OperationCanceledException` and then attempt to cancel the same `CancellationToken` that was just cancelled.
* `try/catch` the call to `Cancel`, add a comment1 parent 2060c3c commit d772b6a
1 file changed
+8
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
520 | 520 | | |
521 | 521 | | |
522 | 522 | | |
523 | | - | |
| 523 | + | |
| 524 | + | |
| 525 | + | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
| 530 | + | |
524 | 531 | | |
525 | 532 | | |
526 | 533 | | |
| |||
0 commit comments