microsoft / infersharp

Infer# is an interprocedural and scalable static code analyzer for C#. Via the capabilities of Facebook's Infer, this tool detects null dereferences, resource leaks, and thread-safety violations. It also performs taint flow tracking to detect critical security vulnerabilities like SQL injections.
MIT License
730 stars 29 forks source link

New resource leak unit test for #113

Closed xi-liu-ds closed 2 years ago

xi-liu-ds commented 2 years ago

In this PR, we add a new unit test to reflect the fix we had in backend, in which now an interprocedural cleanup function can close the dangling global resource. Such as the following example shows:

image