Skip to content

Conversation

@tomasevicius
Copy link

Task.Delay with infinite timespan is neither awaited nor cancelled thus stays running forever and leaks CancellationTokenRegistration object defined in DelayPromiseWithCancellation.

@ailtonguitar
Copy link
Contributor

Hi @tomasevicius ! Thanks for your contribution!

Is it possible to create tests to cover this scenario? Also, can you share the benchmark results?

@tomasevicius
Copy link
Author

Hi @tomasevicius ! Thanks for your contribution!

Is it possible to create tests to cover this scenario? Also, can you share the benchmark results?

Hi, this change is not modifying any functionality, it is purely technical, thus existing tests should be enough.
I don't think I can create a meaningful test to prove that a function used and properly disposed a resource (Task in this case).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants