-
由 Manish Vasani 提交于
Fixes VSO Bug [199252](https://devdiv.visualstudio.com/DefaultCollection/DevDiv/_workitems?_a=edit&id=199252) Root cause: We were attempting to access the cancellation token for a cancellation token source within a lambda within the using statement for the token source. If client fires a cancellation before the task within the lambda executes, the token source may have been disposed when the task is eventually activated. Fix: This change saves the cancellation token for the token source upfront for use within the lambda and also checks for cancellation before computing diagnostics. Justification for ask mode: We are hitting this intermittent crash in perf runs in an internal VSO branch and fix doesn't have any risks.
63fa06b1