Closed dscopra closed 7 years ago
The answer from Noseration on stackoverflow convinced me, that the deregistration should part of your cleanup. Otherwise the lifetime your registration is bound to the parent CancellationtokenSource, which might not be under your control. So I will undo this fix.
Disposing CancellationTokenRegistration is considered as "unregister the callback" and therefore should not be marked as undisposed See msdn: https://msdn.microsoft.com/en-us/library/system.threading.cancellationtokenregistration(v=vs.110).aspx